Logo Search packages:      
Sourcecode: mapserver version File versions  Download package

mapscript_wrap.c

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

#define SWIGPYTHON

#include "Python.h"

/*************************************************************** -*- c -*-
 * python/precommon.swg
 *
 * Rename all exported symbols from common.swg, to avoid symbol
 * clashes if multiple interpreters are included
 *
 ************************************************************************/

#define SWIG_TypeRegister    SWIG_Python_TypeRegister
#define SWIG_TypeCheck       SWIG_Python_TypeCheck
#define SWIG_TypeCast        SWIG_Python_TypeCast
#define SWIG_TypeDynamicCast SWIG_Python_TypeDynamicCast
#define SWIG_TypeName        SWIG_Python_TypeName
#define SWIG_TypeQuery       SWIG_Python_TypeQuery
#define SWIG_TypeClientData  SWIG_Python_TypeClientData
#define SWIG_PackData        SWIG_Python_PackData 
#define SWIG_UnpackData      SWIG_Python_UnpackData 


/***********************************************************************
 * common.swg
 *
 *     This file contains generic SWIG runtime support for pointer
 *     type checking as well as a few commonly used macros to control
 *     external linkage.
 *
 * Author : David Beazley (beazley@cs.uchicago.edu)
 *
 * Copyright (c) 1999-2000, The University of Chicago
 * 
 * This file may be freely redistributed without license or fee provided
 * this copyright message remains intact.
 ************************************************************************/

#include <string.h>

#if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
#  if defined(_MSC_VER) || defined(__GNUC__)
#    if defined(STATIC_LINKED)
#      define SWIGEXPORT(a) a
#      define SWIGIMPORT(a) extern a
#    else
#      define SWIGEXPORT(a) __declspec(dllexport) a
#      define SWIGIMPORT(a) extern a
#    endif
#  else
#    if defined(__BORLANDC__)
#      define SWIGEXPORT(a) a _export
#      define SWIGIMPORT(a) a _export
#    else
#      define SWIGEXPORT(a) a
#      define SWIGIMPORT(a) a
#    endif
#  endif
#else
#  define SWIGEXPORT(a) a
#  define SWIGIMPORT(a) a
#endif

#ifdef SWIG_GLOBAL
#  define SWIGRUNTIME(a) SWIGEXPORT(a)
#else
#  define SWIGRUNTIME(a) static a
#endif

#ifdef __cplusplus
extern "C" {
#endif

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

typedef struct swig_type_info {
  const char             *name;
  swig_converter_func     converter;
  const char             *str;
  void                   *clientdata;
  swig_dycast_func        dcast;
  struct swig_type_info  *next;
  struct swig_type_info  *prev;
} swig_type_info;

#ifdef SWIG_NOINCLUDE

SWIGIMPORT(swig_type_info *) SWIG_TypeRegister(swig_type_info *);
SWIGIMPORT(swig_type_info *) SWIG_TypeCheck(char *c, swig_type_info *);
SWIGIMPORT(void *)           SWIG_TypeCast(swig_type_info *, void *);
SWIGIMPORT(swig_type_info *) SWIG_TypeDynamicCast(swig_type_info *, void **);
SWIGIMPORT(const char *)     SWIG_TypeName(const swig_type_info *);
SWIGIMPORT(swig_type_info *) SWIG_TypeQuery(const char *);
SWIGIMPORT(void)             SWIG_TypeClientData(swig_type_info *, void *);
SWIGIMPORT(char *)           SWIG_PackData(char *, void *, int);
SWIGIMPORT(char *)           SWIG_UnpackData(char *, void *, int);

#else

static swig_type_info *swig_type_list = 0;

/* Register a type mapping with the type-checking */
SWIGRUNTIME(swig_type_info *)
SWIG_TypeRegister(swig_type_info *ti) {
  swig_type_info *tc, *head, *ret, *next;
  /* Check to see if this type has already been registered */
  tc = swig_type_list;
  while (tc) {
    if (strcmp(tc->name, ti->name) == 0) {
      /* Already exists in the table.  Just add additional types to the list */
      if (tc->clientdata) ti->clientdata = tc->clientdata;
      head = tc;
      next = tc->next;
      goto l1;
    }
    tc = tc->prev;
  }
  head = ti;
  next = 0;

  /* Place in list */
  ti->prev = swig_type_list;
  swig_type_list = ti;

  /* Build linked lists */
  l1:
  ret = head;
  tc = ti + 1;
  /* Patch up the rest of the links */
  while (tc->name) {
    head->next = tc;
    tc->prev = head;
    head = tc;
    tc++;
  }
  if (next) next->prev = head;
  head->next = next;
  return ret;
}

/* Check the typename */
SWIGRUNTIME(swig_type_info *) 
SWIG_TypeCheck(char *c, swig_type_info *ty) {
  swig_type_info *s;
  if (!ty) return 0;        /* Void pointer */
  s = ty->next;             /* First element always just a name */
  do {
    if (strcmp(s->name,c) == 0) {
      if (s == ty->next) return s;
      /* Move s to the top of the linked list */
      s->prev->next = s->next;
      if (s->next) {
        s->next->prev = s->prev;
      }
      /* Insert s as second element in the list */
      s->next = ty->next;
      if (ty->next) ty->next->prev = s;
      ty->next = s;
      s->prev = ty;
      return s;
    }
    s = s->next;
  } while (s && (s != ty->next));
  return 0;
}

/* Cast a pointer up an inheritance hierarchy */
SWIGRUNTIME(void *) 
SWIG_TypeCast(swig_type_info *ty, void *ptr) {
  if ((!ty) || (!ty->converter)) return ptr;
  return (*ty->converter)(ptr);
}

/* Dynamic pointer casting. Down an inheritance hierarchy */
SWIGRUNTIME(swig_type_info *) 
SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr) {
  swig_type_info *lastty = ty;
  if (!ty || !ty->dcast) return ty;
  while (ty && (ty->dcast)) {
    ty = (*ty->dcast)(ptr);
    if (ty) lastty = ty;
  }
  return lastty;
}

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

/* Search for a swig_type_info structure */
SWIGRUNTIME(swig_type_info *)
SWIG_TypeQuery(const char *name) {
  swig_type_info *ty = swig_type_list;
  while (ty) {
    if (ty->str && (strcmp(name,ty->str) == 0)) return ty;
    if (ty->name && (strcmp(name,ty->name) == 0)) return ty;
    ty = ty->prev;
  }
  return 0;
}

/* Set the clientdata field for a type */
SWIGRUNTIME(void)
SWIG_TypeClientData(swig_type_info *ti, void *clientdata) {
  swig_type_info *tc, *equiv;
  if (ti->clientdata == clientdata) return;
  ti->clientdata = clientdata;
  equiv = ti->next;
  while (equiv) {
    if (!equiv->converter) {
      tc = swig_type_list;
      while (tc) {
        if ((strcmp(tc->name, equiv->name) == 0))
          SWIG_TypeClientData(tc,clientdata);
        tc = tc->prev;
      }
    }
    equiv = equiv->next;
  }
}

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

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

#endif

#ifdef __cplusplus
}
#endif

/***********************************************************************
 * python.swg
 *
 *     This file contains the runtime support for Python modules
 *     and includes code for managing global variables and pointer
 *     type checking.
 *
 * Author : David Beazley (beazley@cs.uchicago.edu)
 ************************************************************************/

#include "Python.h"

#ifdef __cplusplus
extern "C" {
#endif

#define SWIG_PY_INT     1
#define SWIG_PY_FLOAT   2
#define SWIG_PY_STRING  3
#define SWIG_PY_POINTER 4
#define SWIG_PY_BINARY  5

/* Flags for pointer conversion */

#define SWIG_POINTER_EXCEPTION     0x1
#define SWIG_POINTER_DISOWN        0x2

/* Exception handling in wrappers */
#define SWIG_fail   goto fail

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

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

/* Python-specific SWIG API */
#define SWIG_newvarlink() \
  SWIG_Python_newvarlink()
#define SWIG_addvarlink(p, name, get_attr, set_attr) \
  SWIG_Python_addvarlink(p, name, get_attr, set_attr)
#define SWIG_ConvertPacked(obj, ptr, sz, ty, flags) \
  SWIG_Python_ConvertPacked(obj, ptr, sz, ty, flags)
#define SWIG_NewPackedObj(ptr, sz, type) \
  SWIG_Python_NewPackedObj(ptr, sz, type)
#define SWIG_InstallConstants(d, constants) \
  SWIG_Python_InstallConstants(d, constants)

#ifdef SWIG_NOINCLUDE

SWIGIMPORT(int)               SWIG_Python_ConvertPtr(PyObject *, void **, swig_type_info *, int);
SWIGIMPORT(PyObject *)        SWIG_Python_NewPointerObj(void *, swig_type_info *,int own);
SWIGIMPORT(void *)            SWIG_Python_MustGetPtr(PyObject *, swig_type_info *, int, int);
SWIGIMPORT(PyObject *)        SWIG_Python_newvarlink(void);
SWIGIMPORT(void)              SWIG_Python_addvarlink(PyObject *, char *, PyObject *(*)(void), int (*)(PyObject *));
SWIGIMPORT(int)               SWIG_Python_ConvertPacked(PyObject *, void *, int sz, swig_type_info *, int);
SWIGIMPORT(PyObject *)        SWIG_Python_NewPackedObj(void *, int sz, swig_type_info *);
SWIGIMPORT(void)              SWIG_Python_InstallConstants(PyObject *d, swig_const_info constants[]);

#else

/* -----------------------------------------------------------------------------
 * global variable support code.
 * ----------------------------------------------------------------------------- */

typedef struct swig_globalvar {   
  char       *name;                  /* Name of global variable */
  PyObject *(*get_attr)(void);       /* Return the current value */
  int       (*set_attr)(PyObject *); /* Set the value */
  struct swig_globalvar *next;
} swig_globalvar;

typedef struct swig_varlinkobject {
  PyObject_HEAD
  swig_globalvar *vars;
} swig_varlinkobject;

static PyObject *
swig_varlink_repr(swig_varlinkobject *v) {
  v = v;
  return PyString_FromString("<Global variables>");
}

static int
swig_varlink_print(swig_varlinkobject *v, FILE *fp, int flags) {
  swig_globalvar  *var;
  flags = flags;
  fprintf(fp,"Global variables { ");
  for (var = v->vars; var; var=var->next) {
    fprintf(fp,"%s", var->name);
    if (var->next) fprintf(fp,", ");
  }
  fprintf(fp," }\n");
  return 0;
}

static PyObject *
swig_varlink_getattr(swig_varlinkobject *v, char *n) {
  swig_globalvar *var = v->vars;
  while (var) {
    if (strcmp(var->name,n) == 0) {
      return (*var->get_attr)();
    }
    var = var->next;
  }
  PyErr_SetString(PyExc_NameError,"Unknown C global variable");
  return NULL;
}

static int
swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) {
  swig_globalvar *var = v->vars;
  while (var) {
    if (strcmp(var->name,n) == 0) {
      return (*var->set_attr)(p);
    }
    var = var->next;
  }
  PyErr_SetString(PyExc_NameError,"Unknown C global variable");
  return 1;
}

statichere PyTypeObject varlinktype = {
  PyObject_HEAD_INIT(0)              
  0,
  (char *)"swigvarlink",              /* Type name    */
  sizeof(swig_varlinkobject),         /* Basic size   */
  0,                                  /* Itemsize     */
  0,                                  /* Deallocator  */ 
  (printfunc) swig_varlink_print,     /* Print        */
  (getattrfunc) swig_varlink_getattr, /* get attr     */
  (setattrfunc) swig_varlink_setattr, /* Set attr     */
  0,                                  /* tp_compare   */
  (reprfunc) swig_varlink_repr,       /* tp_repr      */    
  0,                                  /* tp_as_number */
  0,                                  /* tp_as_mapping*/
  0,                                  /* tp_hash      */
};

/* Create a variable linking object for use later */
SWIGRUNTIME(PyObject *)
SWIG_Python_newvarlink(void) {
  swig_varlinkobject *result = 0;
  result = PyMem_NEW(swig_varlinkobject,1);
  varlinktype.ob_type = &PyType_Type;    /* Patch varlinktype into a PyType */
  result->ob_type = &varlinktype;
  result->vars = 0;
  result->ob_refcnt = 0;
  Py_XINCREF((PyObject *) result);
  return ((PyObject*) result);
}

SWIGRUNTIME(void)
SWIG_Python_addvarlink(PyObject *p, char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) {
  swig_varlinkobject *v;
  swig_globalvar *gv;
  v= (swig_varlinkobject *) p;
  gv = (swig_globalvar *) malloc(sizeof(swig_globalvar));
  gv->name = (char *) malloc(strlen(name)+1);
  strcpy(gv->name,name);
  gv->get_attr = get_attr;
  gv->set_attr = set_attr;
  gv->next = v->vars;
  v->vars = gv;
}

/* Convert a pointer value */
SWIGRUNTIME(int)
SWIG_Python_ConvertPtr(PyObject *obj, void **ptr, swig_type_info *ty, int flags) {
  swig_type_info *tc;
  char  *c = 0;
  static PyObject *SWIG_this = 0;
  int    newref = 0;
  PyObject  *pyobj = 0;

  if (!obj) return 0;
  if (obj == Py_None) {
    *ptr = 0;
    return 0;
  }
#ifdef SWIG_COBJECT_TYPES
  if (!(PyCObject_Check(obj))) {
    if (!SWIG_this)
      SWIG_this = PyString_FromString("this");
    pyobj = obj;
    obj = PyObject_GetAttr(obj,SWIG_this);
    newref = 1;
    if (!obj) goto type_error;
    if (!PyCObject_Check(obj)) {
      Py_DECREF(obj);
      goto type_error;
    }
  }  
  *ptr = PyCObject_AsVoidPtr(obj);
  c = (char *) PyCObject_GetDesc(obj);
  if (newref) Py_DECREF(obj);
  goto cobject;
#else
  if (!(PyString_Check(obj))) {
    if (!SWIG_this)
      SWIG_this = PyString_FromString("this");
    pyobj = obj;
    obj = PyObject_GetAttr(obj,SWIG_this);
    newref = 1;
    if (!obj) goto type_error;
    if (!PyString_Check(obj)) {
      Py_DECREF(obj);
      goto type_error;
    }
  } 
  c = PyString_AsString(obj);
  /* Pointer values must start with leading underscore */
  if (*c != '_') {
    *ptr = (void *) 0;
    if (strcmp(c,"NULL") == 0) {
      if (newref) { Py_DECREF(obj); }
      return 0;
    } else {
      if (newref) { Py_DECREF(obj); }
      goto type_error;
    }
  }
  c++;
  c = SWIG_UnpackData(c,ptr,sizeof(void *));
  if (newref) { Py_DECREF(obj); }
#endif

#ifdef SWIG_COBJECT_TYPES
cobject:
#endif

  if (ty) {
    tc = SWIG_TypeCheck(c,ty);
    if (!tc) goto type_error;
    *ptr = SWIG_TypeCast(tc,(void*) *ptr);
  }

  if ((pyobj) && (flags & SWIG_POINTER_DISOWN)) {
    PyObject *zero = PyInt_FromLong(0);
    PyObject_SetAttrString(pyobj,(char*)"thisown",zero);
    Py_DECREF(zero);
  }
  return 0;

type_error:
  if (flags & SWIG_POINTER_EXCEPTION) {
    if (ty && c) {
      char *temp = (char *) malloc(64+strlen(ty->name)+strlen(c));
      sprintf(temp,"Type error. Got %s, expected %s", c, ty->name);
      PyErr_SetString(PyExc_TypeError, temp);
      free((char *) temp);
    } else {
      PyErr_SetString(PyExc_TypeError,"Expected a pointer");
    }
  }
  return -1;
}

/* Convert a pointer value, signal an exception on a type mismatch */
SWIGRUNTIME(void *)
SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int argnum, int flags) {
  void *result;
  SWIG_Python_ConvertPtr(obj, &result, ty, flags | SWIG_POINTER_EXCEPTION);
  return result;
}

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

  if ((!obj) || (!PyString_Check(obj))) goto type_error;
  c = PyString_AsString(obj);
  /* Pointer values must start with leading underscore */
  if (*c != '_') goto type_error;
  c++;
  c = SWIG_UnpackData(c,ptr,sz);
  if (ty) {
    tc = SWIG_TypeCheck(c,ty);
    if (!tc) goto type_error;
  }
  return 0;

type_error:

  if (flags) {
    if (ty && c) {
      char *temp = (char *) malloc(64+strlen(ty->name)+strlen(c));
      sprintf(temp,"Type error. Got %s, expected %s", c, ty->name);
      PyErr_SetString(PyExc_TypeError, temp);
      free((char *) temp);
    } else {
      PyErr_SetString(PyExc_TypeError,"Expected a pointer");
    }
  }
  return -1;
}

/* Create a new pointer object */
SWIGRUNTIME(PyObject *)
SWIG_Python_NewPointerObj(void *ptr, swig_type_info *type, int own) {
  PyObject *robj;
  if (!ptr) {
    Py_INCREF(Py_None);
    return Py_None;
  }
#ifdef SWIG_COBJECT_TYPES
  robj = PyCObject_FromVoidPtrAndDesc((void *) ptr, (char *) type->name, NULL);
#else
  {
    char result[1024];
    char *r = result;
    *(r++) = '_';
    r = SWIG_PackData(r,&ptr,sizeof(void *));
    strcpy(r,type->name);
    robj = PyString_FromString(result);
  }
#endif
  if (!robj || (robj == Py_None)) return robj;
  if (type->clientdata) {
    PyObject *inst;
    PyObject *args = Py_BuildValue((char*)"(O)", robj);
    Py_DECREF(robj);
    inst = PyObject_CallObject((PyObject *) type->clientdata, args);
    Py_DECREF(args);
    if (inst) {
      if (own) {
        PyObject *n = PyInt_FromLong(1);
        PyObject_SetAttrString(inst,(char*)"thisown",n);
        Py_DECREF(n);
      }
      robj = inst;
    }
  }
  return robj;
}

SWIGRUNTIME(PyObject *)
SWIG_Python_NewPackedObj(void *ptr, int sz, swig_type_info *type) {
  char result[1024];
  char *r = result;
  if ((2*sz + 1 + strlen(type->name)) > 1000) return 0;
  *(r++) = '_';
  r = SWIG_PackData(r,ptr,sz);
  strcpy(r,type->name);
  return PyString_FromString(result);
}

/* Install Constants */
SWIGRUNTIME(void)
SWIG_Python_InstallConstants(PyObject *d, swig_const_info constants[]) {
  int i;
  PyObject *obj;
  for (i = 0; constants[i].type; i++) {
    switch(constants[i].type) {
    case SWIG_PY_INT:
      obj = PyInt_FromLong(constants[i].lvalue);
      break;
    case SWIG_PY_FLOAT:
      obj = PyFloat_FromDouble(constants[i].dvalue);
      break;
    case SWIG_PY_STRING:
      obj = PyString_FromString((char *) constants[i].pvalue);
      break;
    case SWIG_PY_POINTER:
      obj = SWIG_NewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
      break;
    case SWIG_PY_BINARY:
      obj = SWIG_NewPackedObj(constants[i].pvalue, constants[i].lvalue, *(constants[i].ptype));
      break;
    default:
      obj = 0;
      break;
    }
    if (obj) {
      PyDict_SetItemString(d,constants[i].name,obj);
      Py_DECREF(obj);
    }
  }
}

#endif

/* Contract support */

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

#ifdef __cplusplus
}
#endif


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

#define  SWIGTYPE_p_resultCacheMemberObj swig_types[0] 
#define  SWIGTYPE_p_markerCacheMemberObj swig_types[1] 
#define  SWIGTYPE_p_labelCacheMemberObj swig_types[2] 
#define  SWIGTYPE_p_layer_obj swig_types[3] 
#define  SWIGTYPE_p_lineObj swig_types[4] 
#define  SWIGTYPE_p_pointObj swig_types[5] 
#define  SWIGTYPE_p_map_obj swig_types[6] 
#define  SWIGTYPE_p_p_char swig_types[7] 
#define  SWIGTYPE_p_mapObj swig_types[8] 
#define  SWIGTYPE_p_resultCacheObj swig_types[9] 
#define  SWIGTYPE_p_labelCacheObj swig_types[10] 
#define  SWIGTYPE_p_char swig_types[11] 
#define  SWIGTYPE_p_imageObj swig_types[12] 
#define  SWIGTYPE_p_hashTableObj swig_types[13] 
#define  SWIGTYPE_p_symbolObj swig_types[14] 
#define  SWIGTYPE_p_shapefileObj swig_types[15] 
#define  SWIGTYPE_p_labelObj swig_types[16] 
#define  SWIGTYPE_p_colorObj swig_types[17] 
#define  SWIGTYPE_p_cgiRequestObj swig_types[18] 
#define  SWIGTYPE_p_rectObj swig_types[19] 
#define  SWIGTYPE_p_webObj swig_types[20] 
#define  SWIGTYPE_p_DBFInfo swig_types[21] 
#define  SWIGTYPE_p_layerObj swig_types[22] 
#define  SWIGTYPE_p_scalebarObj swig_types[23] 
#define  SWIGTYPE_p_referenceMapObj swig_types[24] 
#define  SWIGTYPE_p_queryMapObj swig_types[25] 
#define  SWIGTYPE_p_symbolSetObj swig_types[26] 
#define  SWIGTYPE_p_fontSetObj swig_types[27] 
#define  SWIGTYPE_p_shapeObj swig_types[28] 
#define  SWIGTYPE_p_projectionObj swig_types[29] 
#define  SWIGTYPE_p_intarray swig_types[30] 
#define  SWIGTYPE_p_FILE swig_types[31] 
#define  SWIGTYPE_p_classObj swig_types[32] 
#define  SWIGTYPE_p_errorObj swig_types[33] 
#define  SWIGTYPE_p_int swig_types[34] 
#define  SWIGTYPE_p_styleObj swig_types[35] 
#define  SWIGTYPE_p_labelPathObj swig_types[36] 
#define  SWIGTYPE_p_p_outputFormatObj swig_types[37] 
#define  SWIGTYPE_p_outputFormatObj swig_types[38] 
#define  SWIGTYPE_p_legendObj swig_types[39] 
static swig_type_info *swig_types[41];

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


/*-----------------------------------------------
              @(target):= _mapscript.so
  ------------------------------------------------*/
#define SWIG_init    init_mapscript

#define SWIG_name    "_mapscript"

#include "../../map.h"
#include "../../maptemplate.h"
#include "../../mapogcsld.h"
#include "../../mapows.h"
#include "../../cgiutil.h"
#include "../../mapcopy.h"
#include "../../maperror.h"
#include "../../mapprimitive.h"
#include "../../mapshape.h"

#ifdef SWIGPYTHON
#include "pygdioctx/pygdioctx.h"
#endif



#define  SWIG_MemoryError    1
#define  SWIG_IOError        2
#define  SWIG_RuntimeError   3
#define  SWIG_IndexError     4
#define  SWIG_TypeError      5
#define  SWIG_DivisionByZero 6
#define  SWIG_OverflowError  7
#define  SWIG_SyntaxError    8
#define  SWIG_ValueError     9
#define  SWIG_SystemError   10
#define  SWIG_UnknownError  99


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

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


typedef int intarray;

intarray *new_intarray(int nelements){
  return (int *) calloc(nelements,sizeof(int));
}
void delete_intarray(intarray *self){
  free(self);
}
int intarray_getitem(intarray *self,int index){
  return self[index];
}
void intarray_setitem(intarray *self,int index,int value){
  self[index] = value;
}
int *intarray_cast(intarray *self){
  return self;
}
intarray *intarray_frompointer(int *t){
  return (intarray *) t;
}

#ifdef __cplusplus
extern "C" {
#endif

typedef struct {
    unsigned char *data;
    int size;
    int owns_data;
} gdBuffer;

#ifdef __cplusplus
}
#endif


PyObject *MSExc_MapServerError;
PyObject *MSExc_MapServerChildError;



static void _raise_ms_exception( void );

static void _raise_ms_exception() {
    int errcode;
    errorObj *ms_error;
    char *errmsg;
    ms_error = msGetErrorObj();
    errcode = ms_error->code;
    errmsg = msGetErrorString("\n");
    
    switch (errcode) {
        case MS_IOERR:
            PyErr_SetString(PyExc_IOError, errmsg);
            break;
        case MS_MEMERR:
            PyErr_SetString(PyExc_MemoryError, errmsg);
            break;
        case MS_TYPEERR:
            PyErr_SetString(PyExc_TypeError, errmsg);
            break;
        case MS_EOFERR:
            PyErr_SetString(PyExc_EOFError, errmsg);
            break;
        case MS_CHILDERR:
            PyErr_SetString(MSExc_MapServerChildError, errmsg);
            break;
        default:
            PyErr_SetString(MSExc_MapServerError, errmsg);
            break;
    }

    free(errmsg);
}
  

outputFormatObj *new_outputFormatObj(char const *driver,char *name){
        outputFormatObj *format;

        format = msCreateDefaultOutputFormat(NULL, driver);

        /* in the case of unsupported formats, msCreateDefaultOutputFormat
           should return NULL */
        if (!format)
        {
            msSetError(12, "Unsupported format driver: %s",
                       "outputFormatObj()", driver);
            return NULL;
        }
        
        /* Else, continue */
        format->refcount++;
      format->inmapfile = 1;

        if (name != NULL)
        {
            free(format->name);
            format->name = strdup(name);
        }
        return format;
    }
void delete_outputFormatObj(outputFormatObj *self){
        if ( --self->refcount < 1 )
            msFreeOutputFormat( self );
    }
void outputFormatObj_setExtension(outputFormatObj *self,char const *extension){
        msFree( self->extension );
        self->extension = strdup(extension);
    }
void outputFormatObj_setMimetype(outputFormatObj *self,char const *mimetype){
        msFree( self->mimetype );
        self->mimetype = strdup(mimetype);
    }
void outputFormatObj_setOption(outputFormatObj *self,char const *key,char const *value){
        msSetOutputFormatOption( self, key, value );
    }
int outputFormatObj_validate(outputFormatObj *self){
            return msOutputFormatValidate( self );
    }
char *outputFormatObj_getOption(outputFormatObj *self,char const *key,char const *value){
        const char *retval;
        retval = msGetOutputFormatOption(self, key, value);
        return strdup(retval);
    }
webObj *new_webObj(){
        webObj *web;
        web = (webObj *) malloc(sizeof(webObj));
        initWeb(web);
        return web;
    }
void delete_webObj(webObj *self){
        if (!self) return;
      freeWeb(self);
        free(self);
    }
styleObj *new_styleObj(classObj *parent_class){
    
        styleObj *style;
        int result;
        
        if (!parent_class) 
        { 
            style = (styleObj *) malloc(sizeof(styleObj));
            if (!style) return NULL;
            result = initStyle(style);
            if (result == MS_SUCCESS) 
            {
                style->isachild = 0;
                return style;
            }
            else 
            {
                msSetError(12, "Failed to initialize styleObj",
                                       "styleObj()");
                return NULL;
            }
        }
        else 
        {
            if (parent_class->numstyles == 5) 
            {
                msSetError(31, "Exceeded max number of styles: %d",
                           "styleObj()", 5);
                return NULL;
            }
            parent_class->numstyles++;
            return &(parent_class->styles[parent_class->numstyles-1]);
        }
    }
void delete_styleObj(styleObj *self){
        if (self->isachild == 0) 
            free(self);
    }
styleObj *styleObj_clone(styleObj *self){
        styleObj *style;

        style = (styleObj *) malloc(sizeof(styleObj));
        if (!style)
        {
            msSetError(2,
                "Could not allocate memory for new styleObj instance",
                "clone()");
            return NULL;
        }
        if (initStyle(style) == -1)
        {
            msSetError(2, "Failed to initialize Style",
                                  "clone()");
            return NULL;
        }

        if (msCopyStyle(style, self) != MS_SUCCESS)
        {
            free(style);
            return NULL;
        }
        
        style->isachild = 0;
        return style;
    }
int styleObj_setSymbolByName(styleObj *self,mapObj *map,char *symbolname){
        self->symbol = msGetSymbolIndex(&map->symbolset, symbolname, 1);
        if (self->symbolname) free((char*)self->symbolname);
        if (symbolname) self->symbolname = strdup(symbolname);
        else self->symbolname = 0;
        return self->symbol;
      }
classObj *new_classObj(layerObj *layer){
        classObj *new_class=NULL;
        
        if (!layer)
        {
            new_class = (classObj *) malloc(sizeof(classObj));
            if (!new_class)
            {
                msSetError(2,
                    "Could not allocate memory for new classObj instance",
                    "classObj()");
                return NULL;
            }
            if (initClass(new_class) == -1) return NULL;
            new_class->layer = NULL;
            return new_class;
        }
        else
        {
            if (layer->numclasses == 250)
            {
                msSetError(31, "Max number of classes reached",
                           "classObj()");
                return NULL;
            }
            if (initClass(&(layer->class[layer->numclasses])) == -1)
                return NULL;
            layer->class[layer->numclasses].type = layer->type;
            layer->class[layer->numclasses].layer = layer;
            layer->numclasses++;
            return &(layer->class[layer->numclasses-1]);
        }

        return NULL;
    }
void delete_classObj(classObj *self){
        if (!self->layer)
        {
            freeClass(self);
            free(self);
        }
    }
classObj *classObj_clone(classObj *self){
        classObj *new_class;

        new_class = (classObj *) malloc(sizeof(classObj));
        if (!new_class)
        {
            msSetError(2,
                "Could not allocate memory for new classObj instance",
                "clone()");
            return NULL;
        }
        if (initClass(new_class) == -1)
        {
            msSetError(2, "Failed to initialize Class",
                                  "clone()");
            return NULL;
        }
        new_class->layer = NULL;

        if (msCopyClass(new_class, self, self->layer) != MS_SUCCESS) {
            freeClass(new_class);
            free(new_class);
            new_class = NULL;
        }
        
        return new_class;
    }
int classObj_setExpression(classObj *self,char *expression){
    if (!expression || strlen(expression) == 0) {
       freeExpression(&self->expression);
       return MS_SUCCESS;
    }
    else return msLoadExpressionString(&self->expression, expression);
  }
char *classObj_getExpressionString(classObj *self){
    return msGetExpressionString(&(self->expression));
  }
int classObj_setText(classObj *self,char *text){
    if (!text || strlen(text) == 0) {
      freeExpression(&self->text);
      return MS_SUCCESS;
    } 
    else return msLoadExpressionString(&self->text, text);
  }
char *classObj_getTextString(classObj *self){
    return msGetExpressionString(&(self->text));
  }
char *classObj_getMetaData(classObj *self,char *name){
    char *value = NULL;
    if (!name) {
      msSetError(16, "NULL key", "getMetaData");
    }
     
    value = (char *) msLookupHashTable(&(self->metadata), name);
    if (!value) {
      msSetError(16, "Key %s does not exist", "getMetaData", name);
      return NULL;
    }
    return value;
  }
int classObj_setMetaData(classObj *self,char *name,char *value){
    if (msInsertHashTable(&(self->metadata), name, value) == NULL)
        return MS_FAILURE;
    return MS_SUCCESS;
  }
char *classObj_getFirstMetaDataKey(classObj *self){
    return (char *) msFirstKeyFromHashTable(&(self->metadata));
  }
char *classObj_getNextMetaDataKey(classObj *self,char *lastkey){
    return (char *) msNextKeyFromHashTable(&(self->metadata), lastkey);
  }
int classObj_drawLegendIcon(classObj *self,mapObj *map,layerObj *layer,int width,int height,imageObj *dstImage,int dstX,int dstY){
    return msDrawLegendIcon(map, layer, self, width, height, dstImage->img.gd, dstX, dstY);
  }
imageObj *classObj_createLegendIcon(classObj *self,mapObj *map,layerObj *layer,int width,int height){
    return msCreateLegendIcon(map, layer, self, width, height);
  }
styleObj *classObj_getStyle(classObj *self,int i){
        if (i >= 0 && i < self->numstyles)      
            return &(self->styles[i]);
        else {
            msSetError(31, "Invalid index: %d", "getStyle()", i);
            return NULL;
        }
    }
int classObj_insertStyle(classObj *self,styleObj *style,int index){
        return msInsertStyle(self, style, index);
    }
styleObj *classObj_removeStyle(classObj *self,int index){
        return (styleObj *) msRemoveStyle(self, index);
    }
int classObj_moveStyleUp(classObj *self,int index){
        return msMoveStyleUp(self, index);
    }
int classObj_moveStyleDown(classObj *self,int index){
       return msMoveStyleDown(self, index);
    }
void labelCacheObj_freeCache(labelCacheObj *self){
        msFreeLabelCache(self);    
    }
resultCacheMemberObj *resultCacheObj_getResult(resultCacheObj *self,int i){
        if (i >= 0 && i < self->numresults) {
            return &self->results[i];
        }
        return NULL;
    }
symbolSetObj *new_symbolSetObj(char const *symbolfile){
        symbolSetObj *symbolset;
        mapObj *temp_map=NULL;
        symbolset = (symbolSetObj *) malloc(sizeof(symbolSetObj));
        msInitSymbolSet(symbolset);
        if (symbolfile) {
            symbolset->filename = strdup(symbolfile);
            temp_map = msNewMapObj();
            msLoadSymbolSet(symbolset, temp_map);
            symbolset->map = NULL;
            msFreeMap(temp_map);
        }
        return symbolset;
    }
void delete_symbolSetObj(symbolSetObj *self){
        msFreeSymbolSet(self);
        if (self->filename) free(self->filename);
        free(self);
    }
symbolObj *symbolSetObj_getSymbol(symbolSetObj *self,int i){
        if (i >= 0 && i < self->numsymbols)     
            return (symbolObj *) &(self->symbol[i]);
        else
            return NULL;
    }
symbolObj *symbolSetObj_getSymbolByName(symbolSetObj *self,char *symbolname){
        int i;

        if (!symbolname) return NULL;

        i = msGetSymbolIndex(self, symbolname, 1);
        if (i == -1)
            return NULL;
        else
            return (symbolObj *) &(self->symbol[i]);
    }
int symbolSetObj_index(symbolSetObj *self,char *symbolname){
        return msGetSymbolIndex(self, symbolname, 1);
    }
int symbolSetObj_appendSymbol(symbolSetObj *self,symbolObj *symbol){
        return msAppendSymbol(self, symbol);
    }
symbolObj *symbolSetObj_removeSymbol(symbolSetObj *self,int index){
        return (symbolObj *) msRemoveSymbol(self, index);
    }
int symbolSetObj_save(symbolSetObj *self,char const *filename){
        return msSaveSymbolSet(self, filename);
    }
layerObj *new_layerObj(mapObj *map){
        layerObj *layer;
        int result;
        
        if (!map) {
            layer = (layerObj *) malloc(sizeof(layerObj));
            if (!layer) {
                msSetError(2, "Failed to initialize Layer",
                                       "layerObj()");
                return NULL;
            } 
            result = initLayer(layer, NULL);
            if (result == MS_SUCCESS) {
                layer->index = -1;
                return layer;
            }
            else {
                msSetError(2, "Failed to initialize Layer",
                                       "layerObj()");
                return NULL;
            }
        }
        else {
            if (map->numlayers == 200) {
                msSetError(31, "Max number of layers exceeded",
                                        "layerObj()");
                return(NULL);
            }

            if (initLayer(&(map->layers[map->numlayers]), map) == -1)
                return(NULL);

            map->layers[map->numlayers].index = map->numlayers;
            map->layerorder[map->numlayers] = map->numlayers;
            map->numlayers++;

            return &(map->layers[map->numlayers-1]);
        }
    }
void delete_layerObj(layerObj *self){
        if (!self->map) {
            freeLayer(self);
            free(self);
        }
    }
layerObj *layerObj_clone(layerObj *self){
        layerObj *layer;
        int result;

        layer = (layerObj *) malloc(sizeof(layerObj));
        if (!layer) {
            msSetError(2, "Failed to initialize Layer",
                                  "layerObj()");
            return NULL;
        } 
        result = initLayer(layer, NULL);
        if (result != MS_SUCCESS) {
            msSetError(2, "Failed to initialize Layer",
                                  "layerObj()");
            return NULL;
        }

        if (msCopyLayer(layer, self) != MS_SUCCESS) {
            freeLayer(layer);
            free(layer);
            layer = NULL;
        }
        layer->map = NULL;
        layer->index = -1;
        
        return layer;
    }
int layerObj_insertClass(layerObj *self,classObj *classobj,int index){
        return msInsertClass(self, classobj, index);
    }
classObj *layerObj_removeClass(layerObj *self,int index){
        return msRemoveClass(self, index);
    }
int layerObj_open(layerObj *self){
        int status;
        status =  msLayerOpen(self);
        if (status == MS_SUCCESS) {
            return msLayerGetItems(self);
        }
        return status;
    }
int layerObj_whichShapes(layerObj *self,rectObj rect){
        /* 
        ** We assume folks use this like a simple query so retrieve all items with each shape.
        */
        msLayerGetItems(self);
        return msLayerWhichShapes(self, rect);
    }
shapeObj *layerObj_nextShape(layerObj *self){
       int status;
       shapeObj *shape;

       shape = (shapeObj *)malloc(sizeof(shapeObj));
       if (!shape) return NULL;
       msInitShape(shape);

       status = msLayerNextShape(self, shape);
       if(status != MS_SUCCESS) {
         msFreeShape(shape);
       free(shape);
       return NULL;
       } else
         return shape;
    }
void layerObj_close(layerObj *self){
        msLayerClose(self);
    }
shapeObj *layerObj_getFeature(layerObj *self,int shapeindex,int tileindex){
    /* This version properly returns shapeObj and also has its
     * arguments properly ordered so that users can ignore the
     * tileindex if they are not accessing a tileindexed layer.
     * See bug 586:
     * http://mapserver.gis.umn.edu/bugs/show_bug.cgi?id=586 */
        int retval;
        shapeObj *shape;
        shape = (shapeObj *)malloc(sizeof(shapeObj));
        if (!shape)
            return NULL;
        msInitShape(shape);
        shape->type = self->type;
        retval = msLayerGetShape(self, shape, tileindex, shapeindex);
        return shape;
    }
int layerObj_getShape(layerObj *self,shapeObj *shape,int tileindex,int shapeindex){
        return msLayerGetShape(self, shape, tileindex, shapeindex);
    }
int layerObj_getNumResults(layerObj *self){
        if (!self->resultcache) return 0;
        return self->resultcache->numresults;
    }
resultCacheMemberObj *layerObj_getResult(layerObj *self,int i){
        if (!self->resultcache) return NULL;
        if (i >= 0 && i < self->resultcache->numresults)
            return &self->resultcache->results[i]; 
        else
            return NULL;
    }
classObj *layerObj_getClass(layerObj *self,int i){

        if (i >= 0 && i < self->numclasses)
            return &(self->class[i]); 
        else
            return NULL;
    }
char *layerObj_getItem(layerObj *self,int i){
  
        if (i >= 0 && i < self->numitems)
            return (char *) (self->items[i]);
        else
            return NULL;
    }
int layerObj_draw(layerObj *self,mapObj *map,imageObj *image){
        return msDrawLayer(map, self, image);    
    }
int layerObj_drawQuery(layerObj *self,mapObj *map,imageObj *image){
        return msDrawQueryLayer(map, self, image);    
    }
int layerObj_queryByAttributes(layerObj *self,mapObj *map,char *qitem,char *qstring,int mode){
        int status;
        int retval;
        
        status = self->status;
        self->status = 1;
        retval = msQueryByAttributes(map, self->index, qitem, qstring, mode);
        self->status = status;
        return retval;
    }
int layerObj_queryByPoint(layerObj *self,mapObj *map,pointObj *point,int mode,double buffer){
        int status;
        int retval;
        
        status = self->status;
        self->status = 1;
        retval = msQueryByPoint(map, self->index, mode, *point, buffer);
        self->status = status;
        return retval;
    }
int layerObj_queryByRect(layerObj *self,mapObj *map,rectObj rect){
        int status;
        int retval;
        
        status = self->status;
        self->status = 1;
        retval = msQueryByRect(map, self->index, rect);
        self->status = status;
        return retval;
    }
int layerObj_queryByFeatures(layerObj *self,mapObj *map,int slayer){
        int status;
        int retval;
        
        status = self->status;
        self->status = 1;
        retval = msQueryByFeatures(map, self->index, slayer);
        self->status = status;
        return retval;
    }
int layerObj_queryByShape(layerObj *self,mapObj *map,shapeObj *shape){
        int status;
        int retval;
        
        status = self->status;
        self->status = 1;
        retval = msQueryByShape(map, self->index, shape);
        self->status = status;
        return retval;
    }
int layerObj_queryByIndex(layerObj *self,mapObj *map,int tileindex,int shapeindex,int bAddToQuery){
        int status;
        int retval;
        
        status = self->status;
        self->status = 1;
        if (bAddToQuery == 0)
            retval = msQueryByIndex(map, self->index, tileindex, shapeindex);
        else
            retval = msQueryByIndexAdd(map, self->index, tileindex, shapeindex);
        self->status = status;
        return retval;
    }
resultCacheObj *layerObj_getResults(layerObj *self){
        return self->resultcache;
    }
int layerObj_setFilter(layerObj *self,char *filter){
        if (!filter || strlen(filter) == 0) {
            freeExpression(&self->filter);
            return MS_SUCCESS;
        }
        else return msLoadExpressionString(&self->filter, filter);
    }
char *layerObj_getFilterString(layerObj *self){
        return msGetExpressionString(&(self->filter));
    }
int layerObj_setWKTProjection(layerObj *self,char *wkt){
        self->project = 1;
        return msOGCWKT2ProjectionObj(wkt, &(self->projection), self->debug);
    }
char *layerObj_getProjection(layerObj *self){    
        return (char *) msGetProjectionString(&(self->projection));
    }
int layerObj_setProjection(layerObj *self,char *proj4){
        self->project = 1;
        return msLoadProjectionString(&(self->projection), proj4);
    }
int layerObj_addFeature(layerObj *self,shapeObj *shape){    
        self->connectiontype = MS_INLINE;
        if (insertFeatureList(&(self->features), shape) == NULL) 
        return MS_FAILURE;
        return MS_SUCCESS;
    }
int layerObj_getNumFeatures(layerObj *self){
        return msLayerGetNumFeatures(self);
    }
rectObj *layerObj_getExtent(layerObj *self){
        rectObj *extent;
        extent = (rectObj *) malloc(sizeof(rectObj));
        msLayerGetExtent(self, extent);
        return extent;
    }
int layerObj_setExtent(layerObj *self,double minx,double miny,double maxx,double maxy){
        if (minx > maxx || miny > maxy) {
            msSetError(34,
                "{ 'minx': %f , 'miny': %f , 'maxx': %f , 'maxy': %f }",
                "layerObj::setExtent()", minx, miny, maxx, maxy);
            return MS_FAILURE;
        }

        return msLayerSetExtent(self, minx, miny, maxx, maxy);
    }
char *layerObj_getMetaData(layerObj *self,char *name){
        char *value = NULL;
        if (!name) {
            msSetError(16, "NULL key", "getMetaData");
        }
     
        value = (char *) msLookupHashTable(&(self->metadata), name);
      /*
      Umberto, 05/17/2006
      Exceptions should be reserved for situations when a serious error occurred
      and normal program flow must be interrupted.
      In this case returning null should be more that enough.
      */

        if (!value) {
            msSetError(16, "Key %s does not exist", "getMetaData", name);
            return NULL;
        }

        return value;
    }
int layerObj_setMetaData(layerObj *self,char *name,char *value){
        if (msInsertHashTable(&(self->metadata), name, value) == NULL)
        return MS_FAILURE;
        return MS_SUCCESS;
    }
int layerObj_removeMetaData(layerObj *self,char *name){
        return(msRemoveHashTable(&(self->metadata), name));
    }
char *layerObj_getFirstMetaDataKey(layerObj *self){
        return (char *) msFirstKeyFromHashTable(&(self->metadata));
    }
char *layerObj_getNextMetaDataKey(layerObj *self,char *lastkey){
        return (char *) msNextKeyFromHashTable(&(self->metadata), lastkey);
    }
char *layerObj_getWMSFeatureInfoURL(layerObj *self,mapObj *map,int click_x,int click_y,int feature_count,char *info_format){
        return (char *) msWMSGetFeatureInfoURL(map, self, click_x, click_y,
               feature_count, info_format);
    }
char *layerObj_executeWFSGetFeature(layerObj *self,layerObj *layer){
        return (char *) msWFSExecuteGetFeature(layer);
    }
int layerObj_applySLD(layerObj *self,char *sld,char *stylelayer){
        return msSLDApplySLD(self->map, sld, self->index, stylelayer);
    }
int layerObj_applySLDURL(layerObj *self,char *sld,char *stylelayer){
        return msSLDApplySLDURL(self->map, sld, self->index, stylelayer);
    }
char *layerObj_generateSLD(layerObj *self){
        return (char *) msSLDGenerateSLD(self->map, self->index);
    }
int layerObj_isVisible(layerObj *self){
        if (!self->map)
        {
            msSetError(12,
                "visibility has no meaning outside of a map context",
                "isVisible()");
            return MS_FAILURE;
        }
        return msLayerIsVisible(self->map, self);
    }
int layerObj_moveClassUp(layerObj *self,int index){
        return msMoveClassUp(self, index);
    }
int layerObj_moveClassDown(layerObj *self,int index){
        return msMoveClassDown(self, index);
    }
void layerObj_setProcessingKey(layerObj *self,char const *key,char const *value){
         msLayerSetProcessingKey( self, key, value );
    }
void layerObj_setProcessing(layerObj *self,char const *directive){
        msLayerAddProcessing( self, directive );
    }
void layerObj_addProcessing(layerObj *self,char const *directive){
        msLayerAddProcessing( self, directive );
    }
char *layerObj_getProcessing(layerObj *self,int index){
        return (char *) msLayerGetProcessing(self, index);
    }
int layerObj_clearProcessing(layerObj *self){
        return msLayerClearProcessing(self);
    }
mapObj *new_mapObj(char *filename){
        if (filename && strlen(filename))
            return msLoadMap(filename, NULL);
        else { /* create an empty map, no layers etc... */
            return msNewMapObj();
        }      
    }
void delete_mapObj(mapObj *self){
        msFreeMap(self);
    }
mapObj *mapObj_clone(mapObj *self){
        mapObj *dstMap;
        dstMap = msNewMapObj();
        if (msCopyMap(dstMap, self) != MS_SUCCESS) {
            msFreeMap(dstMap);
            dstMap = NULL;
        }
        return dstMap;
    }
int mapObj_insertLayer(mapObj *self,layerObj *layer,int index){
        return msInsertLayer(self, layer, index);  
    }
layerObj *mapObj_removeLayer(mapObj *self,int index){
        return msRemoveLayer(self, index);
    }
int mapObj_setExtent(mapObj *self,double minx,double miny,double maxx,double maxy){ 
      return msMapSetExtent( self, minx, miny, maxx, maxy );
    }
int mapObj_setSize(mapObj *self,int width,int height){
        return msMapSetSize(self, width, height);
    }
int mapObj_setRotation(mapObj *self,double rotation_angle){
        return msMapSetRotation( self, rotation_angle );
    }
layerObj *mapObj_getLayer(mapObj *self,int i){
    if(i >= 0 && i < self->numlayers)     
      return &(self->layers[i]); /* returns an EXISTING layer */
    else
      return NULL;
  }
layerObj *mapObj_getLayerByName(mapObj *self,char *name){
    int i;

    i = msGetLayerIndex(self, name);

    if(i != -1)
      return &(self->layers[i]); /* returns an EXISTING layer */
    else
      return NULL;
  }
int mapObj_getSymbolByName(mapObj *self,char *name){
    return msGetSymbolIndex(&self->symbolset, name, 1);
  }
void mapObj_prepareQuery(mapObj *self){
    int status;

    status = msCalculateScale(self->extent, self->units, self->width, self->height, self->resolution, &self->scale);
    if(status != MS_SUCCESS) self->scale = -1;
  }
imageObj *mapObj_prepareImage(mapObj *self){
    return msPrepareImage(self, 0);
  }
void mapObj_setImageType(mapObj *self,char *imagetype){
      outputFormatObj *format;

      format = msSelectOutputFormat( self, imagetype );
      if( format == NULL )
        msSetError(12, "Unable to find IMAGETYPE '%s'.", 
                 "setImageType()", imagetype );
      else
      {  
          msFree( self->imagetype );
          self->imagetype = strdup(imagetype);
          msApplyOutputFormat( &(self->outputformat), format, -1111, 
                               -1111, -1111 );
      }
  }
void mapObj_selectOutputFormat(mapObj *self,char *imagetype){
        outputFormatObj *format;

        format = msSelectOutputFormat( self, imagetype );
        if ( format == NULL )
              msSetError(12, "Unable to find IMAGETYPE '%s'.", 
                           "setImageType()", imagetype );
        else
        {   
            msFree( self->imagetype );
            self->imagetype = strdup(imagetype);
            msApplyOutputFormat( &(self->outputformat), format, -1111, 
                                 -1111, -1111 );
        }
    }
void mapObj_setOutputFormat(mapObj *self,outputFormatObj *format){
      msApplyOutputFormat( &(self->outputformat), format, -1111, 
                           -1111, -1111 );
  }
imageObj *mapObj_draw(mapObj *self){
    return msDrawMap(self);
  }
imageObj *mapObj_drawQuery(mapObj *self){
    return msDrawQueryMap(self);
  }
imageObj *mapObj_drawLegend(mapObj *self){
    return msDrawLegend(self, 0);
  }
imageObj *mapObj_drawScalebar(mapObj *self){
    return msDrawScalebar(self);
  }
imageObj *mapObj_drawReferenceMap(mapObj *self){
    return msDrawReferenceMap(self);
  }
int mapObj_embedScalebar(mapObj *self,imageObj *image){     
    return msEmbedScalebar(self, image->img.gd);
  }
int mapObj_embedLegend(mapObj *self,imageObj *image){ 
    return msEmbedLegend(self, image->img.gd);
  }
int mapObj_drawLabelCache(mapObj *self,imageObj *image){
    return msDrawLabelCache(image, self);
  }
labelCacheMemberObj *mapObj_getLabel(mapObj *self,int i){
    if(i >= 0 && i < self->labelcache.numlabels)      
      return &(self->labelcache.labels[i]);
    else
      return NULL;
  }
labelCacheMemberObj *mapObj_nextLabel(mapObj *self){
    static int i=0;

    if(i<self->labelcache.numlabels)
      return &(self->labelcache.labels[i++]);
    else
      return NULL;      
  }
int mapObj_queryByPoint(mapObj *self,pointObj *point,int mode,double buffer){
    return msQueryByPoint(self, -1, mode, *point, buffer);
  }
int mapObj_queryByRect(mapObj *self,rectObj rect){
    return msQueryByRect(self, -1, rect);
  }
int mapObj_queryByFeatures(mapObj *self,int slayer){
    return msQueryByFeatures(self, -1, slayer);
  }
int mapObj_queryByShape(mapObj *self,shapeObj *shape){
    return msQueryByShape(self, -1, shape);
  }
int mapObj_setWKTProjection(mapObj *self,char *wkt){
    return msOGCWKT2ProjectionObj(wkt, &(self->projection), self->debug);
  }
char *mapObj_getProjection(mapObj *self){
    return msGetProjectionString(&(self->projection));
  }
int mapObj_setProjection(mapObj *self,char *proj4){
    return msLoadProjectionString(&(self->projection), proj4);
  }
int mapObj_save(mapObj *self,char *filename){
    return msSaveMap(self, filename);
  }
int mapObj_saveQuery(mapObj *self,char *filename){
        return msSaveQuery(self, filename);
    }
int mapObj_loadQuery(mapObj *self,char *filename){
        return msLoadQuery(self, filename);
    }
void mapObj_freeQuery(mapObj *self,int qlayer){
        msQueryFree(self, qlayer);
    }
int mapObj_saveQueryAsGML(mapObj *self,char *filename,char const *ns){
    return msGMLWriteQuery(self, filename, ns);
  }
char *mapObj_getMetaData(mapObj *self,char *name){
    char *value = NULL;
    if (!name) {
      msSetError(16, "NULL key", "getMetaData");
    }
     
    value = (char *) msLookupHashTable(&(self->web.metadata), name);
    if (!value) {
      msSetError(16, "Key %s does not exist", "getMetaData", name);
      return NULL;
    }
    return value;
  }
int mapObj_setMetaData(mapObj *self,char *name,char *value){
    if (msInsertHashTable(&(self->web.metadata), name, value) == NULL)
      return MS_FAILURE;
    return MS_SUCCESS;
  }
int mapObj_removeMetaData(mapObj *self,char *name){
    return(msRemoveHashTable(&(self->web.metadata), name));
  }
char *mapObj_getFirstMetaDataKey(mapObj *self){
    return (char *) msFirstKeyFromHashTable(&(self->web.metadata));
  }
char *mapObj_getNextMetaDataKey(mapObj *self,char *lastkey){
    return (char *) msNextKeyFromHashTable(&(self->web.metadata), lastkey);
  }
int mapObj_setSymbolSet(mapObj *self,char *szFileName){
    msFreeSymbolSet(&self->symbolset);
    msInitSymbolSet(&self->symbolset);
   
    self->symbolset.filename = strdup(szFileName);

    /* Symbolset shares same fontset as main mapfile */
    self->symbolset.fontset = &(self->fontset);

    return msLoadSymbolSet(&self->symbolset, self);
  }
int mapObj_getNumSymbols(mapObj *self){
    return self->symbolset.numsymbols;
  }
int mapObj_setFontSet(mapObj *self,char *filename){
    msFreeFontSet(&(self->fontset));
    msInitFontSet(&(self->fontset));
   
    self->fontset.filename = strdup(filename);

    return msLoadFontSet(&(self->fontset), self);
  }
int mapObj_saveMapContext(mapObj *self,char *szFileName){
    return msSaveMapContext(self, szFileName);
  }
int mapObj_loadMapContext(mapObj *self,char *szFileName,int useUniqueNames){
    return msLoadMapContext(self, szFileName, useUniqueNames);
  }
int mapObj_moveLayerUp(mapObj *self,int layerindex){
    return msMoveLayerUp(self, layerindex);
  }
int mapObj_moveLayerDown(mapObj *self,int layerindex){
    return msMoveLayerDown(self, layerindex);
  }
intarray *mapObj_getLayersDrawingOrder(mapObj *self){
    int i;
    intarray *order;
    order = new_intarray(self->numlayers);
    for (i=0; i<self->numlayers; i++)
        


        intarray_setitem(order, i, self->layerorder[i]);
        
    return order;
  }
int mapObj_setLayersDrawingOrder(mapObj *self,int *panIndexes){
    return  msSetLayersdrawingOrder(self, panIndexes); 
  }
void mapObj_setConfigOption(mapObj *self,char *key,char *value){
    msSetConfigOption(self,key,value);
  }
char *mapObj_getConfigOption(mapObj *self,char *key){
    return (char *) msGetConfigOption(self,key);
  }
void mapObj_applyConfigOptions(mapObj *self){
    msApplyMapConfigOptions( self );
  }
int mapObj_applySLD(mapObj *self,char *sld){
        return msSLDApplySLD(self, sld, -1, NULL);
    }
int mapObj_applySLDURL(mapObj *self,char *sld){
        return msSLDApplySLDURL(self, sld, -1, NULL);
    }
char *mapObj_generateSLD(mapObj *self){
        return (char *) msSLDGenerateSLD(self, -1);
    }
char *mapObj_processTemplate(mapObj *self,int bGenerateImages,char **names,char **values,int numentries){
        return msProcessTemplate(self, bGenerateImages, names, values,
                                 numentries);
    }
char *mapObj_processLegendTemplate(mapObj *self,char **names,char **values,int numentries){
        return msProcessLegendTemplate(self, names, values, numentries);
    }
char *mapObj_processQueryTemplate(mapObj *self,char **names,char **values,int numentries){
        return msProcessQueryTemplate(self, 1, names, values, numentries);
    }
outputFormatObj *mapObj_getOutputFormatByName(mapObj *self,char *name){
        return msSelectOutputFormat(self, name); 
    }
int mapObj_appendOutputFormat(mapObj *self,outputFormatObj *format){
        return msAppendOutputFormat(self, format);
    }
int mapObj_removeOutputFormat(mapObj *self,char *name){
        return msRemoveOutputFormat(self, name);
    }
int mapObj_loadOWSParameters(mapObj *self,cgiRequestObj *request,char *wmtver_string){
        return msMapLoadOWSParameters(self, request, wmtver_string);
    }
int mapObj_OWSDispatch(mapObj *self,cgiRequestObj *req){
      return msOWSDispatch( self, req );
    }
int mapObj_zoomPoint(mapObj *self,int zoomfactor,pointObj *poPixPos,int width,int height,rectObj *poGeorefExt,rectObj *poMaxGeorefExt){
        double      dfGeoPosX, dfGeoPosY;
        double      dfDeltaX, dfDeltaY;
        rectObj     oNewGeorefExt;    
        double      dfNewScale;
        int         bMaxExtSet;
        double      dfDeltaExt;
        double dX, dY;
        
        dfNewScale = 0.0;
        bMaxExtSet = 0;
        dfDeltaExt = -1.0;

        if (poMaxGeorefExt != NULL) { bMaxExtSet = 1; }

        /* ----------------------------------------------------------- */
        /*      check the validity of the parameters.                  */
        /* ----------------------------------------------------------- */
        if (zoomfactor == 0 || 
            width <= 0 ||
            height <= 0 ||
            poGeorefExt == NULL ||
            poPixPos == NULL )
        {
            msSetError(12, "Incorrect arguments", 
                       "mapscript::mapObj::zoomPoint()");
            return MS_FAILURE;
        }

        /* ----------------------------------------------------------- */
        /*      check if the values passed are consistent min > max.   */
        /* ----------------------------------------------------------- */
        if (poGeorefExt->minx >= poGeorefExt->maxx)
        {
            msSetError(12, "Georeferenced coordinates minx >= maxx",
                       "mapscript::mapObj::zoomPoint()");
            return MS_FAILURE;
        }
        if (poGeorefExt->miny >= poGeorefExt->maxy)
        {
            msSetError(12, "Georeferenced coordinates miny >= maxy",
                       "mapscript::mapObj::zoomPoint()");
            return MS_FAILURE;
        }
        if (bMaxExtSet == 1)
        {
            if (poMaxGeorefExt->minx >= poMaxGeorefExt->maxx)
            {
                msSetError(12, 
                           "Max Georeferenced coordinates minx >= maxx",
                           "mapscript::mapObj::zoomPoint()");
                return MS_FAILURE;
            }
            if (poMaxGeorefExt->miny >= poMaxGeorefExt->maxy)
            {
                msSetError(12, 
                           "Max Georeferenced coordinates miny >= maxy",
                           "mapscript::mapObj::zoomPoint()");
            }
        }
   
        dfDeltaX = poGeorefExt->maxx - poGeorefExt->minx;
        dfDeltaY = poGeorefExt->maxy - poGeorefExt->miny;
        dX = dfDeltaX/(double)width;
        dY = dfDeltaY/(double)height;
        dfGeoPosX = poGeorefExt->minx + dX * (double)poPixPos->x;
        dfGeoPosY = poGeorefExt->maxy - dY * (double)poPixPos->y;
        
        /* --- -------------------------------------------------------- */
        /*      zoom in                                                 */
        /* ------------------------------------------------------------ */
        if (zoomfactor > 1)
        {
            oNewGeorefExt.minx = dfGeoPosX - (dfDeltaX/(2*zoomfactor));        
            oNewGeorefExt.miny = dfGeoPosY - (dfDeltaY/(2*zoomfactor));        
            oNewGeorefExt.maxx = dfGeoPosX + (dfDeltaX/(2*zoomfactor));        
            oNewGeorefExt.maxy = dfGeoPosY + (dfDeltaY/(2*zoomfactor));
        }

        if (zoomfactor < 0)
        {
            oNewGeorefExt.minx = dfGeoPosX - (dfDeltaX/2)*(abs(zoomfactor));    
            oNewGeorefExt.miny = dfGeoPosY - (dfDeltaY/2)*(abs(zoomfactor));    
            oNewGeorefExt.maxx = dfGeoPosX + (dfDeltaX/2)*(abs(zoomfactor));    
            oNewGeorefExt.maxy = dfGeoPosY + (dfDeltaY/2)*(abs(zoomfactor));
        }
        if (zoomfactor == 1)
        {
            oNewGeorefExt.minx = dfGeoPosX - (dfDeltaX/2);
            oNewGeorefExt.miny = dfGeoPosY - (dfDeltaY/2);
            oNewGeorefExt.maxx = dfGeoPosX + (dfDeltaX/2);
            oNewGeorefExt.maxy = dfGeoPosY + (dfDeltaY/2);
        }

        /* ------------------------------------------------------------ */
        /*   if the min and max scale are set in the map file, we will  */
        /*   use them to test before zooming.                           */
        /* ------------------------------------------------------------ */
        msAdjustExtent(&oNewGeorefExt, self->width, self->height);
        msCalculateScale(oNewGeorefExt, self->units, 
                             self->width, self->height, 
                             self->resolution, &dfNewScale);
    
        if (self->web.maxscale > 0)
        {
            if (zoomfactor < 0 && dfNewScale > self->web.maxscale)
            {
                return MS_FAILURE;
            }
        }

        /* ============================================================ */
        /*  we do a spcial case for zoom in : we try to zoom as much as */
        /*  possible using the mincale set in the .map.                 */
        /* ============================================================ */
        if (self->web.minscale > 0 &&
            dfNewScale < self->web.minscale &&
            zoomfactor > 1)
        {
            dfDeltaExt = (self->web.minscale * self->width)
                       /(self->resolution * msInchesPerUnit(self->units,0));
            /*dfDeltaExt = 
                GetDeltaExtentsUsingScale(self->web.minscale, self->units,
                                          dfGeoPosY, self->width, 
                                          self->resolution);*/
            if (dfDeltaExt > 0.0)
            {
                oNewGeorefExt.minx = dfGeoPosX - (dfDeltaExt/2);
                oNewGeorefExt.miny = dfGeoPosY - (dfDeltaExt/2);
                oNewGeorefExt.maxx = dfGeoPosX + (dfDeltaExt/2);
                oNewGeorefExt.maxy = dfGeoPosY + (dfDeltaExt/2);
            }
            else
                return MS_FAILURE;
        }

        /* ------------------------------------------------------------ */
        /*  If the buffer is set, make sure that the extents do not go  */
        /*  beyond the buffer.                                          */
        /* ------------------------------------------------------------ */
        if (bMaxExtSet)
        {
            dfDeltaX = oNewGeorefExt.maxx - oNewGeorefExt.minx;
            dfDeltaY = oNewGeorefExt.maxy - oNewGeorefExt.miny;
        
            /* Make sure Current georef extents is not bigger than 
             * max extents */
            if (dfDeltaX > (poMaxGeorefExt->maxx-poMaxGeorefExt->minx))
                dfDeltaX = poMaxGeorefExt->maxx-poMaxGeorefExt->minx;
            if (dfDeltaY > (poMaxGeorefExt->maxy-poMaxGeorefExt->miny))
                dfDeltaY = poMaxGeorefExt->maxy-poMaxGeorefExt->miny;

            if (oNewGeorefExt.minx < poMaxGeorefExt->minx)
            {
                oNewGeorefExt.minx = poMaxGeorefExt->minx;
                oNewGeorefExt.maxx =  oNewGeorefExt.minx + dfDeltaX;
            }
            if (oNewGeorefExt.maxx > poMaxGeorefExt->maxx)
            {
                oNewGeorefExt.maxx = poMaxGeorefExt->maxx;
                oNewGeorefExt.minx = oNewGeorefExt.maxx - dfDeltaX;
            }
            if (oNewGeorefExt.miny < poMaxGeorefExt->miny)
            {
                oNewGeorefExt.miny = poMaxGeorefExt->miny;
                oNewGeorefExt.maxy =  oNewGeorefExt.miny + dfDeltaY;
            }
            if (oNewGeorefExt.maxy > poMaxGeorefExt->maxy)
            {
                oNewGeorefExt.maxy = poMaxGeorefExt->maxy;
                oNewGeorefExt.miny = oNewGeorefExt.maxy - dfDeltaY;
            }
        }
    
        /* ------------------------------------------------------------ */
        /*      set the map extents with new values.                    */
        /* ------------------------------------------------------------ */
        self->extent.minx = oNewGeorefExt.minx;
        self->extent.miny = oNewGeorefExt.miny;
        self->extent.maxx = oNewGeorefExt.maxx;
        self->extent.maxy = oNewGeorefExt.maxy;
    
        self->cellsize = msAdjustExtent(&(self->extent), self->width, 
                                        self->height);      
        dfDeltaX = self->extent.maxx - self->extent.minx;
        dfDeltaY = self->extent.maxy - self->extent.miny; 

        if (bMaxExtSet)
        {
            if (self->extent.minx < poMaxGeorefExt->minx)
            {
                self->extent.minx = poMaxGeorefExt->minx;
                self->extent.maxx = self->extent.minx + dfDeltaX;
            }
            if (self->extent.maxx > poMaxGeorefExt->maxx)
            {
                self->extent.maxx = poMaxGeorefExt->maxx;
                oNewGeorefExt.minx = oNewGeorefExt.maxx - dfDeltaX;
            }
            if (self->extent.miny < poMaxGeorefExt->miny)
            {
                self->extent.miny = poMaxGeorefExt->miny;
                self->extent.maxy =  self->extent.miny + dfDeltaY;
            }
            if (self->extent.maxy > poMaxGeorefExt->maxy)
            {
                self->extent.maxy = poMaxGeorefExt->maxy;
                oNewGeorefExt.miny = oNewGeorefExt.maxy - dfDeltaY;
            }
        }
    
        msCalculateScale(self->extent, self->units, self->width, 
                         self->height, self->resolution, &(self->scale));
        return MS_SUCCESS;

    }
int mapObj_zoomRectangle(mapObj *self,rectObj *poPixRect,int width,int height,rectObj *poGeorefExt,rectObj *poMaxGeorefExt){
        double      dfDeltaX, dfDeltaY;
        rectObj     oNewGeorefExt;    
        double      dfNewScale;
        double      dfDeltaExt;
        double dfMiddleX, dfMiddleY;
        double dX, dY;
        int bMaxExtSet;
        
        bMaxExtSet = 0;
        dfNewScale = 0.0;
        dfDeltaExt = -1.0;

        if (poMaxGeorefExt != NULL) { bMaxExtSet = 1; }

        /* ----------------------------------------------------------- */
        /*      check the validity of the parameters.                  */
        /* ----------------------------------------------------------- */
        if (poPixRect == 0 || 
            width <= 0 ||
            height <= 0 ||
            poGeorefExt == NULL )
        {
            msSetError(12, "Incorrect arguments", 
                       "mapscript::mapObj::zoomRectangle");
            return MS_FAILURE;
        }

        /* ----------------------------------------------------------- */
        /*      check if the values passed are consistent min > max.   */
        /* ----------------------------------------------------------- */
        if (poPixRect->minx >= poPixRect->maxx)
        {
            msSetError(12, "image rectangle minx >= maxx",
                       "mapscript::mapObj::zoomRectangle()");
            return MS_FAILURE;
        }
        if (poPixRect->maxy >= poPixRect->miny)
        {
            msSetError(12, "image rectangle miny >= maxy",
                       "mapscript::mapObj::zoomRectangle()");
            return MS_FAILURE;
        }

        if (poGeorefExt->minx >= poGeorefExt->maxx)
        {
            msSetError(12, "Georeferenced coordinates minx >= maxx",
                       "mapscript::mapObj::zoomRectangle()");
            return MS_FAILURE;
        }
        if (poGeorefExt->miny >= poGeorefExt->maxy)
        {
            msSetError(12, "Georeferenced coordinates miny >= maxy",
                       "mapscript::mapObj::zoomRectangle()");
            return MS_FAILURE;
        }
        if (bMaxExtSet == 1)
        {
            if (poMaxGeorefExt->minx >= poMaxGeorefExt->maxx)
            {
                msSetError(12, 
                           "Max Georeferenced coordinates minx >= maxx",
                           "mapscript::mapObj::zoomRectangle()");
                return MS_FAILURE;
            }
            if (poMaxGeorefExt->miny >= poMaxGeorefExt->maxy)
            {
                msSetError(12, 
                           "Max Georeferenced coordinates miny >= maxy",
                           "mapscript::mapObj::zoomRectangle()");
            }
        }

  
        /* ----------------------------------------------------------- */
        /*   Convert pixel rectangle to georeferenced rectangle        */
        /* ----------------------------------------------------------- */
        
        dfDeltaX = poGeorefExt->maxx - poGeorefExt->minx;
        dfDeltaY = poGeorefExt->maxy - poGeorefExt->miny;
        dX = dfDeltaX/(double)width;
        dY = dfDeltaY/(double)height;

        oNewGeorefExt.minx = poGeorefExt->minx
                           + dX * (double)poPixRect->minx;
        oNewGeorefExt.miny = poGeorefExt->maxy
                           - dY * (double)poPixRect->miny;
        oNewGeorefExt.maxx = poGeorefExt->minx
                           + dX * (double)poPixRect->maxx;
        oNewGeorefExt.maxy = poGeorefExt->maxy
                           - dY * (double)poPixRect->maxy;

        msAdjustExtent(&oNewGeorefExt, self->width, self->height);

        /* ------------------------------------------------------------ */
        /*   if the min and max scale are set in the map file, we will  */
        /*   use them to test before setting extents.                   */
        /* ------------------------------------------------------------ */
        msCalculateScale(oNewGeorefExt, self->units, 
                         self->width, self->height, 
                         self->resolution, &dfNewScale);

        if (self->web.maxscale > 0 &&  dfNewScale > self->web.maxscale)
        {
            return MS_FAILURE;
        }

        if (self->web.minscale > 0 && dfNewScale <  self->web.minscale)
        {
            dfMiddleX = oNewGeorefExt.minx + 
                ((oNewGeorefExt.maxx - oNewGeorefExt.minx)/2);
            dfMiddleY = oNewGeorefExt.miny + 
                ((oNewGeorefExt.maxy - oNewGeorefExt.miny)/2);
        
            dfDeltaExt = (self->web.minscale * self->width)
                       / (self->resolution * msInchesPerUnit(self->units,0));
            /*dfDeltaExt = 
                GetDeltaExtentsUsingScale(self->web.minscale, self->units, 
                                          dfMiddleY, self->width, 
                                      self->resolution);*/

            if (dfDeltaExt > 0.0)
            {
                oNewGeorefExt.minx = dfMiddleX - (dfDeltaExt/2);
                oNewGeorefExt.miny = dfMiddleY - (dfDeltaExt/2);
                oNewGeorefExt.maxx = dfMiddleX + (dfDeltaExt/2);
                oNewGeorefExt.maxy = dfMiddleY + (dfDeltaExt/2);
            }
            else
                return MS_FAILURE;
        }

        /* ------------------------------------------------------------ */
        /*  If the buffer is set, make sure that the extents do not go  */
        /*  beyond the buffer.                                          */
        /* ------------------------------------------------------------ */
        if (bMaxExtSet)
        {
            dfDeltaX = oNewGeorefExt.maxx - oNewGeorefExt.minx;
            dfDeltaY = oNewGeorefExt.maxy - oNewGeorefExt.miny;
        
            /* Make sure Current georef extents is not bigger 
             * than max extents */
            if (dfDeltaX > (poMaxGeorefExt->maxx-poMaxGeorefExt->minx))
                dfDeltaX = poMaxGeorefExt->maxx-poMaxGeorefExt->minx;
            if (dfDeltaY > (poMaxGeorefExt->maxy-poMaxGeorefExt->miny))
                dfDeltaY = poMaxGeorefExt->maxy-poMaxGeorefExt->miny;

            if (oNewGeorefExt.minx < poMaxGeorefExt->minx)
            {
                oNewGeorefExt.minx = poMaxGeorefExt->minx;
                oNewGeorefExt.maxx =  oNewGeorefExt.minx + dfDeltaX;
            }
            if (oNewGeorefExt.maxx > poMaxGeorefExt->maxx)
            {
                oNewGeorefExt.maxx = poMaxGeorefExt->maxx;
                oNewGeorefExt.minx = oNewGeorefExt.maxx - dfDeltaX;
            }
            if (oNewGeorefExt.miny < poMaxGeorefExt->miny)
            {
                oNewGeorefExt.miny = poMaxGeorefExt->miny;
                oNewGeorefExt.maxy =  oNewGeorefExt.miny + dfDeltaY;
            }
            if (oNewGeorefExt.maxy > poMaxGeorefExt->maxy)
            {
                oNewGeorefExt.maxy = poMaxGeorefExt->maxy;
                oNewGeorefExt.miny = oNewGeorefExt.maxy - dfDeltaY;
            }
        }

        self->extent.minx = oNewGeorefExt.minx;
        self->extent.miny = oNewGeorefExt.miny;
        self->extent.maxx = oNewGeorefExt.maxx;
        self->extent.maxy = oNewGeorefExt.maxy;
    
        self->cellsize = msAdjustExtent(&(self->extent), self->width, 
                                        self->height);    
        dfDeltaX = self->extent.maxx - self->extent.minx;
        dfDeltaY = self->extent.maxy - self->extent.miny; 

        if (bMaxExtSet)
        {
            if (self->extent.minx < poMaxGeorefExt->minx)
            {
                self->extent.minx = poMaxGeorefExt->minx;
                self->extent.maxx = self->extent.minx + dfDeltaX;
            }
            if (self->extent.maxx > poMaxGeorefExt->maxx)
            {
                self->extent.maxx = poMaxGeorefExt->maxx;
                oNewGeorefExt.minx = oNewGeorefExt.maxx - dfDeltaX;
            }
            if (self->extent.miny < poMaxGeorefExt->miny)
            {
                self->extent.miny = poMaxGeorefExt->miny;
                self->extent.maxy =  self->extent.miny + dfDeltaY;
            }
            if (self->extent.maxy > poMaxGeorefExt->maxy)
            {
                self->extent.maxy = poMaxGeorefExt->maxy;
                oNewGeorefExt.miny = oNewGeorefExt.maxy - dfDeltaY;
            }
        }

        msCalculateScale(self->extent, self->units, self->width, 
                         self->height, self->resolution, &(self->scale));
        return MS_SUCCESS;

    }
int mapObj_zoomScale(mapObj *self,double scale,pointObj *poPixPos,int width,int height,rectObj *poGeorefExt,rectObj *poMaxGeorefExt){
        double      dfGeoPosX, dfGeoPosY;
        double      dfDeltaX, dfDeltaY;
        rectObj     oNewGeorefExt;    
        double      dfNewScale, dfCurrentScale;
        int         bMaxExtSet;
        int nTmp;
        double      dfDeltaExt;
        double dX, dY;
        
        dfNewScale = 0.0;
        dfCurrentScale = 0.0;
        nTmp = 0;
        bMaxExtSet = 0;
        dfDeltaExt = -1.0;

        if (poMaxGeorefExt != NULL) { bMaxExtSet = 1; }

        /* ----------------------------------------------------------- */
        /*      check the validity of the parameters.                  */
        /* ----------------------------------------------------------- */
        if (scale <= 0.0 || 
            width <= 0 ||
            height <= 0 ||
            poGeorefExt == NULL ||
            poPixPos == NULL )
        {
            msSetError(12, "Incorrect arguments", 
                       "mapscript::mapObj::zoomScale");
            return MS_FAILURE;
        }

        /* ----------------------------------------------------------- */
        /*      check if the values passed are consistent min > max.   */
        /* ----------------------------------------------------------- */
        if (poGeorefExt->minx >= poGeorefExt->maxx)
        {
            msSetError(12, "Georeferenced coordinates minx >= maxx",
                       "mapscript::mapObj::zoomScale()");
            return MS_FAILURE;
        }
        if (poGeorefExt->miny >= poGeorefExt->maxy)
        {
            msSetError(12, "Georeferenced coordinates miny >= maxy",
                       "mapscript::mapObj::zoomScale()");
            return MS_FAILURE;
        }
        if (bMaxExtSet == 1)
        {
            if (poMaxGeorefExt->minx >= poMaxGeorefExt->maxx)
            {
                msSetError(12, 
                           "Max Georeferenced coordinates minx >= maxx",
                           "mapscript::mapObj::zoomScale()");
                return MS_FAILURE;
            }
            if (poMaxGeorefExt->miny >= poMaxGeorefExt->maxy)
            {
                msSetError(12, 
                           "Max Georeferenced coordinates miny >= maxy",
                           "mapscript::mapObj::zoomScale()");
            }
        }
   
        dfDeltaX = poGeorefExt->maxx - poGeorefExt->minx;
        dfDeltaY = poGeorefExt->maxy - poGeorefExt->miny;
        dX = dfDeltaX/(double)width;
        dY = dfDeltaY/(double)height;
        dfGeoPosX = poGeorefExt->minx + dX * (double)poPixPos->x;
        dfGeoPosY = poGeorefExt->maxy - dY * (double)poPixPos->y;
        
        /* ------------------------------------------------------------ */
        /*  Calculate new extents based on the scale.                   */
        /* ------------------------------------------------------------ */

        /* ============================================================ */
        /*  make sure to take the smallest size because this is the one */
        /*  that will be used to ajust the scale.                       */
        /* ============================================================ */

        if (self->width <  self->height)
            nTmp = self->width;
        else
            nTmp = self->height;

        dfDeltaExt=scale*nTmp/(self->resolution*msInchesPerUnit(self->units,0));

        if (dfDeltaExt > 0.0)
        {
            oNewGeorefExt.minx = dfGeoPosX - (dfDeltaExt/2);
            oNewGeorefExt.miny = dfGeoPosY - (dfDeltaExt/2);
            oNewGeorefExt.maxx = dfGeoPosX + (dfDeltaExt/2);
            oNewGeorefExt.maxy = dfGeoPosY + (dfDeltaExt/2);
        }
        else
            return MS_FAILURE;

        /* ------------------------------------------------------------ */
        /*   get current scale.                                         */
        /* ------------------------------------------------------------ */
        msCalculateScale(*poGeorefExt, self->units, 
                         self->width, self->height,
                         self->resolution, &dfCurrentScale);

        /* ------------------------------------------------------------ *
         *   if the min and max scale are set in the map file, we will  *
         *   use them to test before zooming.                           *
         *                                                              *
         *   This function has the same effect as zoomin or zoom out.
         *   If the current scale is > newscale we zoom in; else it is
         *   a zoom out.
         * ------------------------------------------------------------ */
        msAdjustExtent(&oNewGeorefExt, self->width, self->height);
        msCalculateScale(oNewGeorefExt, self->units, 
                         self->width, self->height,
                         self->resolution, &dfNewScale);

        if (self->web.maxscale > 0)
        {
            if (dfCurrentScale < dfNewScale && dfNewScale >  self->web.maxscale)
            {
                return MS_FAILURE;
            }
        }

        /* ============================================================ */
        /* we do a special case for zoom in : we try to zoom as much as */
        /* possible using the mincale set in the .map.                  */
        /* ============================================================ */
        if (self->web.minscale > 0 && dfNewScale <  self->web.minscale &&
            dfCurrentScale > dfNewScale)
        {
            dfDeltaExt=scale*nTmp/(self->resolution*msInchesPerUnit(self->units,0));
            if (dfDeltaExt > 0.0)
            {
                oNewGeorefExt.minx = dfGeoPosX - (dfDeltaExt/2);
                oNewGeorefExt.miny = dfGeoPosY - (dfDeltaExt/2);
                oNewGeorefExt.maxx = dfGeoPosX + (dfDeltaExt/2);
                oNewGeorefExt.maxy = dfGeoPosY + (dfDeltaExt/2);
            }
            else
                return MS_FAILURE;
        }

        /* ------------------------------------------------------------ */
        /*  If the buffer is set, make sure that the extents do not go  */
        /*  beyond the buffer.                                          */
        /* ------------------------------------------------------------ */
        if (bMaxExtSet)
        {
            dfDeltaX = oNewGeorefExt.maxx - oNewGeorefExt.minx;
            dfDeltaY = oNewGeorefExt.maxy - oNewGeorefExt.miny;
        
            /* Make sure Current georef extents is not bigger 
             * than max extents */
            if (dfDeltaX > (poMaxGeorefExt->maxx-poMaxGeorefExt->minx))
                dfDeltaX = poMaxGeorefExt->maxx-poMaxGeorefExt->minx;
            if (dfDeltaY > (poMaxGeorefExt->maxy-poMaxGeorefExt->miny))
                dfDeltaY = poMaxGeorefExt->maxy-poMaxGeorefExt->miny;

            if (oNewGeorefExt.minx < poMaxGeorefExt->minx)
            {
                oNewGeorefExt.minx = poMaxGeorefExt->minx;
                oNewGeorefExt.maxx =  oNewGeorefExt.minx + dfDeltaX;
            }
            if (oNewGeorefExt.maxx > poMaxGeorefExt->maxx)
            {
                oNewGeorefExt.maxx = poMaxGeorefExt->maxx;
                oNewGeorefExt.minx = oNewGeorefExt.maxx - dfDeltaX;
            }
            if (oNewGeorefExt.miny < poMaxGeorefExt->miny)
            {
                oNewGeorefExt.miny = poMaxGeorefExt->miny;
                oNewGeorefExt.maxy =  oNewGeorefExt.miny + dfDeltaY;
            }
            if (oNewGeorefExt.maxy > poMaxGeorefExt->maxy)
            {
                oNewGeorefExt.maxy = poMaxGeorefExt->maxy;
                oNewGeorefExt.miny = oNewGeorefExt.maxy - dfDeltaY;
            }
        }

        self->extent.minx = oNewGeorefExt.minx;
        self->extent.miny = oNewGeorefExt.miny;
        self->extent.maxx = oNewGeorefExt.maxx;
        self->extent.maxy = oNewGeorefExt.maxy;
    
        self->cellsize = msAdjustExtent(&(self->extent), self->width, 
                                        self->height);    
        dfDeltaX = self->extent.maxx - self->extent.minx;
        dfDeltaY = self->extent.maxy - self->extent.miny; 

        if (bMaxExtSet)
        {
            if (self->extent.minx < poMaxGeorefExt->minx)
            {
                self->extent.minx = poMaxGeorefExt->minx;
                self->extent.maxx = self->extent.minx + dfDeltaX;
            }
            if (self->extent.maxx > poMaxGeorefExt->maxx)
            {
                self->extent.maxx = poMaxGeorefExt->maxx;
                oNewGeorefExt.minx = oNewGeorefExt.maxx - dfDeltaX;
            }
            if (self->extent.miny < poMaxGeorefExt->miny)
            {
                self->extent.miny = poMaxGeorefExt->miny;
                self->extent.maxy =  self->extent.miny + dfDeltaY;
            }
            if (self->extent.maxy > poMaxGeorefExt->maxy)
            {
                self->extent.maxy = poMaxGeorefExt->maxy;
                oNewGeorefExt.miny = oNewGeorefExt.maxy - dfDeltaY;
            }
        }

        msCalculateScale(self->extent, self->units, self->width, 
                         self->height, self->resolution, &(self->scale));
        return MS_SUCCESS;
    }
PyObject *mapObj_getLayerOrder(mapObj *self){
        int i;
        PyObject *order;
        order = PyTuple_New(self->numlayers);
        for (i = 0; i < self->numlayers; i++) {
            PyTuple_SetItem(order,i,PyInt_FromLong((long)self->layerorder[i]));
        }
        return order;
    }
int mapObj_setLayerOrder(mapObj *self,PyObject *order){
        int i, size;
        size = PyTuple_Size(order);
        for (i = 0; i < size; i++) {
            self->layerorder[i] = (int)PyInt_AsLong(PyTuple_GetItem(order, i));
        }
        return MS_SUCCESS;
    }
PyObject *mapObj_getSize(mapObj *self){
        PyObject* output ;
        output = PyTuple_New(2);
        PyTuple_SetItem(output,0,PyInt_FromLong((long)self->width));
        PyTuple_SetItem(output,1,PyInt_FromLong((long)self->height));
        return output;
    }
void delete_imageObj(imageObj *self){
        msFreeImage(self);    
    }
void imageObj_save(imageObj *self,char *filename,mapObj *map){
        msSaveImage(map, self, filename );
    }
gdBuffer imageObj_getBytes(imageObj *self){
        gdBuffer buffer;
        
      buffer.owns_data = 1;
        buffer.data = msSaveImageBufferGD(self->img.gd, &buffer.size,
                                          self->format);
        if( buffer.size == 0 )
        {
            buffer.data = NULL;
            msSetError(12, "Failed to get image buffer", "getBytes");
            return buffer;
        }

        return buffer;
    }
imageObj *new_imageObj(PyObject *arg1,PyObject *arg2,PyObject *input_format){
        imageObj *image=NULL;
        outputFormatObj *format=NULL;
        int width;
        int height;
        PyObject *pybytes;
      
        unsigned char PNGsig[8] = {137, 80, 78, 71, 13, 10, 26, 10};
        unsigned char JPEGsig[3] = {255, 216, 255};

        if (PyInt_Check(arg1) && PyInt_Check(arg2)) 
        {
            /* Create from width, height, format/driver */
            width = (int) PyInt_AsLong(arg1);
            height = (int) PyInt_AsLong(arg2);
            
            if (input_format == Py_None) {
                format = msCreateDefaultOutputFormat(NULL, "GD/GIF");
                if (format == NULL)
                    format = msCreateDefaultOutputFormat(NULL, "GD/PNG");
                if (format == NULL)
                    format = msCreateDefaultOutputFormat(NULL, "GD/JPEG");
                if (format == NULL)
                    format = msCreateDefaultOutputFormat(NULL, "GD/WBMP");
            }
            else if (PyString_Check(input_format)) {
                format = msCreateDefaultOutputFormat(NULL, 
                                PyString_AsString(input_format));
            }
            else {
                if ((SWIG_ConvertPtr(input_format, (void **) &format,
                     SWIGTYPE_p_outputFormatObj,
                     SWIG_POINTER_EXCEPTION | 0 )) == -1) 
                {
                    msSetError(15, "Can't convert format pointer",
                                          "imageObj()");
                    return NULL;
                }
            }
        
            if (format == NULL) {
                msSetError(15, "Could not create output format",
                           "imageObj()");
                return NULL;
            }

            image = msImageCreate(width, height, format, NULL, NULL, NULL);
            return image;
        }
        
        /* Is arg1 a filename? */
        else if (PyString_Check(arg1)) 
        {
            return (imageObj *) msImageLoadGD((char *) PyString_AsString(arg1));
        }
        
        /* Is a file-like object */
        else if (arg1 != Py_None)
        {

            if (PyObject_HasAttrString(arg1, "seek"))
            {
                /* Detect image format */
                pybytes = PyObject_CallMethod(arg1, "read", "i", 8);
                PyObject_CallMethod(arg1, "seek", "i", 0);
            
                if (memcmp(PyString_AsString(pybytes),"GIF8",4)==0) 
                {
#ifdef USE_GD_GIF
                    image = createImageObjFromPyFile(arg1, "GD/GIF");
#else
                    msSetError(12, "Unable to load GIF image.",
                               "imageObj()");
#endif
                }
                else if (memcmp(PyString_AsString(pybytes),PNGsig,8)==0) 
                {
#ifdef USE_GD_PNG
                    image = createImageObjFromPyFile(arg1, "GD/PNG");
#else
                    msSetError(12, "Unable to load PNG image.",
                               "imageObj()");
#endif
                }
                else if (memcmp(PyString_AsString(pybytes),JPEGsig,3)==0) 
                {
#ifdef USE_GD_JPEG
                    image = createImageObjFromPyFile(arg1, "GD/JPEG");
#else
                    msSetError(12, "Unable to load JPEG image.", 
                               "imageObj()");
#endif
                }
                else
                {
                    msSetError(12, "Failed to detect image format.  Likely cause is invalid image or improper filemode.  On windows, Python files should be opened in 'rb' mode.", "imageObj()");
                }

                return image;
            
            }
            else /* such as a url handle */
            {
                /* If there is no seek method, we absolutely must
                   have a driver name */
                if (!PyString_Check(arg2))
                {
                    msSetError(12, "A driver name absolutely must accompany file objects which do not have a seek() method", "imageObj()");
                    return NULL;
                }    
                return (imageObj *) createImageObjFromPyFile(arg1, 
                        PyString_AsString(arg2));
            }
        }
        else 
        {
            msSetError(15, "Failed to create image", 
                       "imageObj()");
            return NULL;
        }
    }
int imageObj_write(imageObj *self,PyObject *file){
        FILE *stream;
        gdIOCtx *ctx;
        unsigned char *imgbuffer;
        int imgsize;
        PyObject *noerr;
        int retval=MS_FAILURE;
       
        /* Return immediately if image driver is not GD */
        if ( !MS_DRIVER_GD(self->format) )
        {
            msSetError(15, "Writing of %s format not implemented",
                       "imageObj::write", self->format->driver);
            return MS_FAILURE;
        }

        if (file == Py_None) /* write to stdout */
        {
            ctx = msNewGDFileCtx(stdout);
            retval = msSaveImageGDCtx(self->img.gd, ctx, self->format);
            ctx->gd_free(ctx);
        }
        else if (PyFile_Check(file)) /* a Python (C) file */
        {
            stream = PyFile_AsFile(file);
            ctx = msNewGDFileCtx(stream);
            retval = msSaveImageGDCtx(self->img.gd, ctx, self->format);
            ctx->gd_free(ctx);
        }
        else /* presume a Python file-like object */
        {
            imgbuffer = msSaveImageBufferGD(self->img.gd, &imgsize,
                                            self->format);
            if (imgsize == 0)
            {
                msSetError(15, "failed to get image buffer", "write()");
                return MS_FAILURE;
            }
                
            noerr = PyObject_CallMethod(file, "write", "s#", imgbuffer,
                                        imgsize);
            gdFree(imgbuffer);
            if (noerr == NULL)
                return MS_FAILURE;
            else
                Py_DECREF(noerr);
            retval = MS_SUCCESS;
        }

        return retval;
    }
PyObject *imageObj_saveToString(imageObj *self){
        int size=0;
        unsigned char *imgbytes;
        PyObject *imgstring; 

        imgbytes = msSaveImageBufferGD(self->img.gd, &size, self->format);
        if (size == 0)
        {
            msSetError(15, "failed to get image buffer", "saveToString()");
            return NULL;
        }
        imgstring = PyString_FromStringAndSize(imgbytes, size); 
        gdFree(imgbytes);
        return imgstring;
    }
rectObj *new_rectObj(double minx,double miny,double maxx,double maxy,int imageunits){     
        rectObj *rect;
    
        if (imageunits == 0)
        { 
            if (minx > maxx || miny > maxy)
            {
                msSetError(34,
                    "{ 'minx': %f , 'miny': %f , 'maxx': %f , 'maxy': %f }",
                    "rectObj()", minx, miny, maxx, maxy);
                return NULL;
            }
        }
        else 
        {
            if (minx > maxx || maxy > miny) 
            {
                msSetError(34,
                    "image (pixel/line) units { 'minx': %f , 'miny': %f , 'maxx': %f , 'maxy': %f }",
                    "rectObj()", minx, miny, maxx, maxy);
                return NULL;
            }
        }
    
        rect = (rectObj *)calloc(1, sizeof(rectObj));
        if (!rect)
            return(NULL);
    
        rect->minx = minx;
        rect->miny = miny;
        rect->maxx = maxx;
        rect->maxy = maxy;

        return(rect);         
    }
void delete_rectObj(rectObj *self){
        free(self);
    }
int rectObj_project(rectObj *self,projectionObj *projin,projectionObj *projout){
        return msProjectRect(projin, projout, self);
    }
double rectObj_fit(rectObj *self,int width,int height){
        return  msAdjustExtent(self, width, height);
    }
int rectObj_draw(rectObj *self,mapObj *map,layerObj *layer,imageObj *image,int classindex,char *text){
        shapeObj shape;

        msInitShape(&shape);
        msRectToPolygon(*self, &shape);
        shape.classindex = classindex;
        shape.text = strdup(text);

        msDrawShape(map, layer, &shape, image, -1);

        msFreeShape(&shape);
    
        return MS_SUCCESS;
    }
shapeObj *rectObj_toPolygon(rectObj *self){
        lineObj line = {0,NULL};
        shapeObj *shape;
        shape = (shapeObj *)malloc(sizeof(shapeObj));
        if (!shape)
            return NULL;
        msInitShape(shape);
        shape->type = MS_SHAPE_POLYGON;
  
        line.point = (pointObj *)malloc(sizeof(pointObj)*5);
        line.point[0].x = self->minx;
        line.point[0].y = self->miny;
        line.point[1].x = self->minx;
        line.point[1].y = self->maxy;
        line.point[2].x = self->maxx;
        line.point[2].y = self->maxy;
        line.point[3].x = self->maxx;
        line.point[3].y = self->miny;
        line.point[4].x = line.point[0].x;
        line.point[4].y = line.point[0].y;
  
        line.numpoints = 5;
  
        msAddLine(shape, &line);
        msComputeBounds(shape);
        
        free(line.point);

        return shape;
    }
char *rectObj_toString(rectObj *self){
        char buffer[256];
        char fmt[]="{ 'minx': %.16g , 'miny': %.16g , 'maxx': %.16g , 'maxy': %.16g }";
        msRectToFormattedString(self, (char *) &fmt, (char *) &buffer, 256);
        return strdup(buffer);
    }
pointObj *new_pointObj(double x,double y,double z,double m){
        pointObj *p;
        p = (pointObj *)calloc(1,sizeof(pointObj));
        if (!p) return NULL;
        p->x = x;
        p->y = y;




        return p;
    }
void delete_pointObj(pointObj *self){
        free(self);
    }
int pointObj_project(pointObj *self,projectionObj *projin,projectionObj *projout){
        return msProjectPoint(projin, projout, self);
    }
int pointObj_draw(pointObj *self,mapObj *map,layerObj *layer,imageObj *image,int classindex,char *text){
        return msDrawPoint(map, layer, self, image, classindex, text);
    }
double pointObj_distanceToPoint(pointObj *self,pointObj *point){
        return msDistancePointToPoint(self, point);
    }
double pointObj_distanceToSegment(pointObj *self,pointObj *a,pointObj *b){
        return msDistancePointToSegment(self, a, b);
    }
double pointObj_distanceToShape(pointObj *self,shapeObj *shape){
        return msDistancePointToShape(self, shape);
    }
int pointObj_setXY(pointObj *self,double x,double y,double m){
        self->x = x;
        self->y = y;




      
        return MS_SUCCESS;
    }
int pointObj_setXYZ(pointObj *self,double x,double y,double z,double m){
        self->x = x;
        self->y = y;




        return MS_SUCCESS;
    }
int pointObj_setXYZM(pointObj *self,double x,double y,double z,double m){
        self->x = x;
        self->y = y;




        return MS_SUCCESS;
    }
char *pointObj_toString(pointObj *self){
        char buffer[256];
        const char *fmt;







        fmt = "{ 'x': %.16g, 'y': %.16g }";

      
        msPointToFormattedString(self, fmt, (char *) &buffer, 256);
        return strdup(buffer);
    }
shapeObj *pointObj_toShape(pointObj *self){
      shapeObj *shape;

      shape = (shapeObj *) malloc(sizeof(shapeObj));
      msInitShape(shape);
    
      shape->type = MS_SHAPE_POINT;
      shape->line = (lineObj *) malloc(sizeof(lineObj));
      shape->numlines = 1;
      shape->line[0].point = (pointObj *) malloc(sizeof(pointObj));
      shape->line[0].numpoints = 1;

      shape->line[0].point[0].x = self->x;
      shape->line[0].point[0].y = self->y;





      return shape;
    }
lineObj *new_lineObj(){
        lineObj *line;

        line = (lineObj *)malloc(sizeof(lineObj));
        if (!line)
            return(NULL);

        line->numpoints=0;
        line->point=NULL;

        return line;
    }
void delete_lineObj(lineObj *self){
        free(self->point);
        free(self);           
    }
int lineObj_project(lineObj *self,projectionObj *projin,projectionObj *projout){
        return msProjectLine(projin, projout, self);
    }
pointObj *lineObj_get(lineObj *self,int i){
        if (i<0 || i>=self->numpoints)
            return NULL;
        else
            return &(self->point[i]);
    }
int lineObj_add(lineObj *self,pointObj *p){
        if (self->numpoints == 0) { /* new */   
        self->point = (pointObj *)malloc(sizeof(pointObj));      
        if (!self->point)
              return MS_FAILURE;
        } else { /* extend array */
            self->point = (pointObj *)realloc(self->point, 
                                      sizeof(pointObj)*(self->numpoints+1));
        if (!self->point)
              return MS_FAILURE;
        }

        self->point[self->numpoints].x = p->x;
        self->point[self->numpoints].y = p->y;
        self->numpoints++;

        return MS_SUCCESS;
    }
int lineObj_set(lineObj *self,int i,pointObj *p){
        if (i<0 || i>=self->numpoints)
            return MS_FAILURE;

        self->point[i].x = p->x;
        self->point[i].y = p->y;
        return MS_SUCCESS;    
    }
shapeObj *new_shapeObj(int type){
        shapeObj *shape;

      shape = (shapeObj *)malloc(sizeof(shapeObj));
        if (!shape)
            return NULL;

        msInitShape(shape);
        if(type >= 0) shape->type = type;
        
        return shape;
    }
void delete_shapeObj(shapeObj *self){
        msFreeShape(self);
        free(self);           
    }
shapeObj *shapeObj_fromWKT(char *wkt){
      shapeObj *shape;
        
        if(!wkt) return NULL;

        shape = msShapeFromWKT(wkt);
      if(!shape) return NULL;

      return shape;
    }
int shapeObj_project(shapeObj *self,projectionObj *projin,projectionObj *projout){
        return msProjectShape(projin, projout, self);
    }
lineObj *shapeObj_get(shapeObj *self,int i){
        if (i<0 || i>=self->numlines)
            return NULL;
        else
            return &(self->line[i]);
    }
int shapeObj_add(shapeObj *self,lineObj *line){
        return msAddLine(self, line);
    }
int shapeObj_draw(shapeObj *self,mapObj *map,layerObj *layer,imageObj *image){
        return msDrawShape(map, layer, self, image, -1);
    }
void shapeObj_setBounds(shapeObj *self){    
        msComputeBounds(self);
        return;
    }
shapeObj *shapeObj_clone(shapeObj *self){
        shapeObj *shape;
        shape = (shapeObj *)malloc(sizeof(shapeObj));
        if (!shape)
            return NULL;
        msInitShape(shape);
        shape->type = self->type;
        msCopyShape(self, shape);
        return shape;
    }
int shapeObj_copy(shapeObj *self,shapeObj *dest){
        return(msCopyShape(self, dest));
    }
char *shapeObj_toWKT(shapeObj *self){
        return msShapeToWKT(self);
    }
shapeObj *shapeObj_buffer(shapeObj *self,double width){ return msGEOSBuffer(self, width); }
shapeObj *shapeObj_convexHull(shapeObj *self){ return msGEOSConvexHull(self); }
shapeObj *shapeObj_boundary(shapeObj *self){ return msGEOSBoundary(self); }
pointObj *shapeObj_getCentroid(shapeObj *self){ return msGEOSGetCentroid(self); }
shapeObj *shapeObj_Union(shapeObj *self,shapeObj *shape){ return msGEOSUnion(self, shape); }
shapeObj *shapeObj_intersection(shapeObj *self,shapeObj *shape){ return msGEOSIntersection(self, shape); }
shapeObj *shapeObj_difference(shapeObj *self,shapeObj *shape){ return msGEOSDifference(self, shape); }
shapeObj *shapeObj_symDifference(shapeObj *self,shapeObj *shape){ return msGEOSSymDifference(self, shape); }
int shapeObj_contains__SWIG_0(shapeObj *self,shapeObj *shape){ return msGEOSContains(self, shape); }
int shapeObj_overlaps(shapeObj *self,shapeObj *shape){ return msGEOSOverlaps(self, shape); }
int shapeObj_within(shapeObj *self,shapeObj *shape){ return msGEOSWithin(self, shape); }
int shapeObj_crosses(shapeObj *self,shapeObj *shape){ return msGEOSCrosses(self, shape); }
int shapeObj_intersects(shapeObj *self,shapeObj *shape){ return msGEOSIntersects(self, shape); }
int shapeObj_touches(shapeObj *self,shapeObj *shape){ return msGEOSTouches(self, shape); }
int shapeObj_equals(shapeObj *self,shapeObj *shape){ return msGEOSEquals(self, shape); }
int shapeObj_disjoint(shapeObj *self,shapeObj *shape){ return msGEOSDisjoint(self, shape); }
double shapeObj_getArea(shapeObj *self){ return msGEOSArea(self); }
double shapeObj_getLength(shapeObj *self){ return msGEOSLength(self); }
char *shapeObj_getValue(shapeObj *self,int i){
        if (i >= 0 && i < self->numvalues && self->values)
            return (self->values[i]);
        else
            return NULL;
    }
int shapeObj_contains__SWIG_1(shapeObj *self,pointObj *point){
        if (self->type == MS_SHAPE_POLYGON)
            return msIntersectPointPolygon(point, self);
        
        return -1;
    }
double shapeObj_distanceToPoint(shapeObj *self,pointObj *point){
        return msDistancePointToShape(point, self); /* should there be a GEOS version of this? */
    }
double shapeObj_distanceToShape(shapeObj *self,shapeObj *shape){
      return msGEOSDistance(self, shape); /* note this calls msDistanceShapeToShape() if GEOS support is not present */
    }
int shapeObj_setValue(shapeObj *self,int i,char *value){
        if (!self->values || !value)
        {
            msSetError(19, "Can't set value", "setValue()");
            return MS_FAILURE;
        }
        if (i >= 0 && i < self->numvalues)
        {
            msFree(self->values[i]);
            self->values[i] = strdup(value);
            if (!self->values[i])
            {
                return MS_FAILURE;
            }
            else return MS_SUCCESS;
        }
        else
        {
            msSetError(19, "Invalid value index", 
                                  "setValue()");
            return MS_FAILURE;
        }
    }
void shapeObj_initValues(shapeObj *self,int numvalues){
        int i;
        
        if(self->values) msFreeCharArray(self->values, self->numvalues);
        self->values = NULL;
        self->numvalues = 0;
        
        /* Allocate memory for the values */
        if (numvalues > 0) {
            if ((self->values = (char **)malloc(sizeof(char *)*numvalues)) == NULL) {
                msSetError(2, "Failed to allocate memory for values", "shapeObj()");
                return;
            } else {
                for (i=0; i<numvalues; i++) self->values[i] = strdup("");
            }
            self->numvalues = numvalues;
        }
    }
char *DBFInfo_getFieldName(DBFInfo *self,int iField){
        static char pszFieldName[1000];
          int pnWidth;
          int pnDecimals;
          msDBFGetFieldInfo(self, iField, &pszFieldName[0], &pnWidth, 
                          &pnDecimals);
          return pszFieldName;
    }
int DBFInfo_getFieldWidth(DBFInfo *self,int iField){
        char pszFieldName[1000];
          int pnWidth;
          int pnDecimals;
          msDBFGetFieldInfo(self, iField, &pszFieldName[0], &pnWidth,
                          &pnDecimals);
          return pnWidth;
    }
int DBFInfo_getFieldDecimals(DBFInfo *self,int iField){
        char pszFieldName[1000];
          int pnWidth;
          int pnDecimals;
          msDBFGetFieldInfo(self, iField, &pszFieldName[0], &pnWidth,
                          &pnDecimals);
          return pnDecimals;
    }
int DBFInfo_getFieldType(DBFInfo *self,int iField){
          return msDBFGetFieldInfo(self, iField, NULL, NULL, NULL);
    }
shapefileObj *new_shapefileObj(char *filename,int type){    
        shapefileObj *shapefile;
        int status;

        shapefile = (shapefileObj *)malloc(sizeof(shapefileObj));
        if (!shapefile)
            return NULL;

        if (type == -1)
            status = msSHPOpenFile(shapefile, "rb", filename);
        else if (type == -2)
            status = msSHPOpenFile(shapefile, "rb+", filename);
        else
            status = msSHPCreateFile(shapefile, filename, type);

        if (status == -1) {
            msSHPCloseFile(shapefile);
            free(shapefile);
            return NULL;
        }
 
        return(shapefile);
    }
void delete_shapefileObj(shapefileObj *self){
        msSHPCloseFile(self);
        free(self);  
    }
int shapefileObj_get(shapefileObj *self,int i,shapeObj *shape){
        if (i<0 || i>=self->numshapes)
            return MS_FAILURE;

        msFreeShape(shape); /* frees all lines and points before re-filling */
        msSHPReadShape(self->hSHP, i, shape);

        return MS_SUCCESS;
    }
shapeObj *shapefileObj_getShape(shapefileObj *self,int i){
        shapeObj *shape;
        shape = (shapeObj *)malloc(sizeof(shapeObj));
        if (!shape)
            return NULL;
        msInitShape(shape);
        shape->type = self->type;
        msSHPReadShape(self->hSHP, i, shape);
        return shape;

    }
int shapefileObj_getPoint(shapefileObj *self,int i,pointObj *point){
        if (i<0 || i>=self->numshapes)
            return MS_FAILURE;

        msSHPReadPoint(self->hSHP, i, point);
        return MS_SUCCESS;
    }
int shapefileObj_getTransformed(shapefileObj *self,mapObj *map,int i,shapeObj *shape){
        if (i<0 || i>=self->numshapes)
            return MS_FAILURE;

        msFreeShape(shape); /* frees all lines and points before re-filling */
        msSHPReadShape(self->hSHP, i, shape);
        msTransformShapeToPixel(shape, map->extent, map->cellsize);

        return MS_SUCCESS;
    }
void shapefileObj_getExtent(shapefileObj *self,int i,rectObj *rect){
        msSHPReadBounds(self->hSHP, i, rect);
    }
int shapefileObj_add(shapefileObj *self,shapeObj *shape){
        /* Trap NULL or empty shapes -- bug 1201 */
        if (!shape) 
        {
            msSetError(19, "Can't add NULL shape", "shapefileObj::add");
            return MS_FAILURE;
        }
        else if (!shape->line)
        {
            msSetError(19, "Can't add empty shape", "shapefileObj::add");
            return MS_FAILURE;
        }

        return msSHPWriteShape(self->hSHP, shape);    
    }
int shapefileObj_addPoint(shapefileObj *self,pointObj *point){    
        return msSHPWritePoint(self->hSHP, point);    
    }
projectionObj *new_projectionObj(char *proj4){
        int status;
        projectionObj *proj=NULL;

        proj = (projectionObj *)malloc(sizeof(projectionObj));
        if (!proj) return NULL;
        msInitProjection(proj);

        status = msLoadProjectionString(proj, proj4);
        if (status == -1) {
            msFreeProjection(proj);
            free(proj);
            return NULL;
        }

        return proj;
    }
void delete_projectionObj(projectionObj *self){
        msFreeProjection(self);
        free(self);           
    }
colorObj *new_colorObj(int red,int green,int blue,int pen){
        colorObj *color;
        
        /* Check colors */
        if (red > 255 || green > 255 || blue > 255) {
            msSetError(12, "Invalid color index.", "colorObj()");
            return NULL;
        }
    
        color = (colorObj *)calloc(1, sizeof(colorObj));
        if (!color)
            return(NULL);
    
        MS_INIT_COLOR(*color, red, green, blue);

        return(color);        
    }
void delete_colorObj(colorObj *self){
        free(self);
    }
int colorObj_setRGB(colorObj *self,int red,int green,int blue){
        /* Check colors */
        if (red > 255 || green > 255 || blue > 255) {
            msSetError(12, "Invalid color index.", "setRGB()");
            return MS_FAILURE;
        }
    
        MS_INIT_COLOR(*self, red, green, blue);
        return MS_SUCCESS;
    }
int colorObj_setHex(colorObj *self,char *psHexColor){
        int red, green, blue;
        if (psHexColor && strlen(psHexColor)== 7 && psHexColor[0] == '#') {
            red = hex2int(psHexColor+1);
            green = hex2int(psHexColor+3);
            blue= hex2int(psHexColor+5);
            if (red > 255 || green > 255 || blue > 255) {
                msSetError(12, "Invalid color index.", "setHex()");
                return MS_FAILURE;
            }

            MS_INIT_COLOR(*self, red, green, blue);
            return MS_SUCCESS;
        }
        else {
            msSetError(12, "Invalid hex color.", "setHex()");
            return MS_FAILURE;
        }
    }
char *colorObj_toHex(colorObj *self){
        char hexcolor[8] = "";

        if (!self) 
        {
            msSetError(12, "Can't express NULL color as hex",
                       "toHex()");
            return NULL;
        }
        if (self->red < 0 || self->green < 0 || self->blue < 0) 
        {
            msSetError(12, "Can't express invalid color as hex",
                       "toHex()");
            return NULL;
        }
        snprintf(hexcolor, 8, "#%02x%02x%02x",
                 self->red, self->green, self->blue);
        return strdup(hexcolor);
    }
symbolObj *new_symbolObj(char *symbolname,char const *imagefile){
        symbolObj *symbol;
        symbol = (symbolObj *) malloc(sizeof(symbolObj));
        initSymbol(symbol);
        symbol->name = strdup(symbolname);
        if (imagefile) {
            msLoadImageSymbol(symbol, imagefile);
        }
        return symbol;
    }
void delete_symbolObj(symbolObj *self){
        if (!self) return;
        if (self->name) free(self->name);
        if (self->img) gdImageDestroy(self->img);
        if (self->font) free(self->font);
        if (self->imagepath) free(self->imagepath);
        free(self);
    }
int symbolObj_setImagepath(symbolObj *self,char const *imagefile){
      return msLoadImageSymbol(self, imagefile);
    }
int symbolObj_setPoints(symbolObj *self,lineObj *line){
        int i;
        for (i=0; i<line->numpoints; i++) {
            MS_COPYPOINT(&(self->points[i]), &(line->point[i]));
        }
        self->numpoints = line->numpoints;
        return self->numpoints;
    }
lineObj *symbolObj_getPoints(symbolObj *self){
        int i;
        lineObj *line;
        line = (lineObj *) malloc(sizeof(lineObj));
        line->point = (pointObj *) malloc(sizeof(pointObj)*(self->numpoints));
        for (i=0; i<self->numpoints; i++) {
            line->point[i].x = self->points[i].x;
            line->point[i].y = self->points[i].y;
        }
        line->numpoints = self->numpoints;
        return line;
    }
int symbolObj_setStyle(symbolObj *self,int index,int value){
        if (index < 0 || index > 10) {
            msSetError(4, "Can't set style at index %d.", "setStyle()", index);
            return MS_FAILURE;
        }
        self->style[index] = value;
        return MS_SUCCESS;
    }
imageObj *symbolObj_getImage(symbolObj *self,outputFormatObj *format){
        return msSymbolGetImageGD(self, format);
    }
int symbolObj_setImage(symbolObj *self,imageObj *image){
        return msSymbolSetImageGD(self, image);
    }
errorObj *new_errorObj(){    
        return msGetErrorObj();
    }
void delete_errorObj(errorObj *self){}
errorObj *errorObj_next(errorObj *self){
        errorObj *ep;   

        if (self == NULL || self->next == NULL) return NULL;

        ep = msGetErrorObj();
        while (ep != self) {
            /* We reached end of list of active errorObj and 
               didn't find the errorObj... this is bad! */
            if (ep->next == NULL) return NULL;
            ep = ep->next;
        }
    
        return ep->next;
    }

#include "../../map.h"


#include "../../maphash.h"

hashTableObj *new_hashTableObj(){

        return msCreateHashTable();
    }
void delete_hashTableObj(hashTableObj *self){
        msFreeHashTable(self);
    }
int hashTableObj_set(hashTableObj *self,char *key,char *value){
        if (msInsertHashTable(self, key, value) == NULL) {
              return MS_FAILURE;
        }
        return MS_SUCCESS;
    }
char *hashTableObj_get(hashTableObj *self,char *key,char *default_value){
        char *value = NULL;
        if (!key) {
            msSetError(16, "NULL key", "get");
        }
     
        value = (char *) msLookupHashTable(self, key);
        if (!value) {
            return default_value;
        }
        return value;
    }
int hashTableObj_remove(hashTableObj *self,char *key){
        return msRemoveHashTable(self, key);
    }
void hashTableObj_clear(hashTableObj *self){
        msFreeHashItems(self);
        initHashTable(self);
    }
char const *hashTableObj_nextKey(hashTableObj *self,char *prevkey){
        return msNextKeyFromHashTable(self, (const char *) prevkey);
    }
cgiRequestObj *new_cgiRequestObj(){
        cgiRequestObj *request;
        
        request = msAllocCgiObj();
        if (!request) {
            msSetError(13, "Failed to initialize object","OWSRequest()");
            return NULL;
        }
        
        request->ParamNames = (char **) malloc(100*sizeof(char*));
        request->ParamValues = (char **) malloc(100*sizeof(char*));
        if (request->ParamNames==NULL || request->ParamValues==NULL) {
              msSetError(2, NULL, "OWSRequest()");
            return NULL;
        }
        return request;
    }
void delete_cgiRequestObj(cgiRequestObj *self){
        msFreeCharArray(self->ParamNames, self->NumParams);
        msFreeCharArray(self->ParamValues, self->NumParams);
        free(self);
    }
int cgiRequestObj_loadParams(cgiRequestObj *self){
      self->NumParams = loadParams( self );
      return self->NumParams;
    }
void cgiRequestObj_setParameter(cgiRequestObj *self,char *name,char *value){
        int i;
        
        if (self->NumParams == 100) {
            msSetError(31, "Maximum number of items, %d, has been reached", "setItem()", 100);
        }
        
        for (i=0; i<self->NumParams; i++) {
            if (strcasecmp(self->ParamNames[i], name) == 0) {
                free(self->ParamValues[i]);
                self->ParamValues[i] = strdup(value);
                break;
            }
        }
        if (i == self->NumParams) {
            self->ParamNames[self->NumParams] = strdup(name);
            self->ParamValues[self->NumParams] = strdup(value);
            self->NumParams++;
        }
    }
char *cgiRequestObj_getName(cgiRequestObj *self,int index){
        if (index < 0 || index >= self->NumParams) {
            msSetError(31, "Invalid index, valid range is [0, %d]", "getName()", self->NumParams-1);
            return NULL;
        }
        return self->ParamNames[index];
    }
char *cgiRequestObj_getValue(cgiRequestObj *self,int index){
        if (index < 0 || index >= self->NumParams) {
            msSetError(31, "Invalid index, valid range is [0, %d]", "getValue()", self->NumParams-1);
            return NULL;
        }
        return self->ParamValues[index];
    }
char *cgiRequestObj_getValueByName(cgiRequestObj *self,char const *name){
        int i;
        for (i=0; i<self->NumParams; i++) {
            if (strcasecmp(self->ParamNames[i], name) == 0) {
                return self->ParamValues[i];
            }
        }
        return NULL;
    }


const char *msIO_getStdoutBufferString() {
    msIOContext *ctx = msIO_getHandler( (FILE *) "stdout" );
    msIOBuffer  *buf;

    if( ctx == NULL || ctx->write_channel == MS_FALSE 
        || strcmp(ctx->label,"buffer") != 0 )
    {
      msSetError( MS_MISCERR, "Can't identify msIO buffer.",
                    "msIO_getStdoutBufferString" );
      return "";
    }

    buf = (msIOBuffer *) ctx->cbData;

    /* write one zero byte and backtrack if it isn't already there */
    if( buf->data_len == 0 || buf->data[buf->data_offset] != '\0' ) {
        msIO_bufferWrite( buf, "", 1 );
      buf->data_offset--;
    }

    return (const char *) (buf->data);
}

gdBuffer msIO_getStdoutBufferBytes() {
    msIOContext *ctx = msIO_getHandler( (FILE *) "stdout" );
    msIOBuffer  *buf;
    gdBuffer     gdBuf;

    if( ctx == NULL || ctx->write_channel == MS_FALSE 
        || strcmp(ctx->label,"buffer") != 0 )
    {
      msSetError( MS_MISCERR, "Can't identify msIO buffer.",
                    "msIO_getStdoutBufferString" );
      gdBuf.data = (unsigned char*)"";
      gdBuf.size = 0;
      gdBuf.owns_data = MS_FALSE;
      return gdBuf;
    }

    buf = (msIOBuffer *) ctx->cbData;

    gdBuf.data = buf->data;
    gdBuf.size = buf->data_offset;
    gdBuf.owns_data = MS_FALSE;

    /* we are seizing ownership of the buffer contents */
    buf->data_offset = 0;
    buf->data_len = 0;
    buf->data = NULL;

    return gdBuf;
}


#ifdef __cplusplus
extern "C" {
#endif
static PyObject *_wrap_new_intarray(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    int arg1 ;
    intarray *result;
    
    if(!PyArg_ParseTuple(args,(char *)"i:new_intarray",&arg1)) goto fail;
    result = (intarray *)new_intarray(arg1);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_intarray, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_intarray(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    intarray *arg1 = (intarray *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_intarray",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_intarray,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    delete_intarray(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_intarray___getitem__(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    intarray *arg1 = (intarray *) 0 ;
    int arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:intarray___getitem__",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_intarray,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int)intarray_getitem(arg1,arg2);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_intarray___setitem__(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    intarray *arg1 = (intarray *) 0 ;
    int arg2 ;
    int arg3 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oii:intarray___setitem__",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_intarray,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    intarray_setitem(arg1,arg2,arg3);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_intarray_cast(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    intarray *arg1 = (intarray *) 0 ;
    int *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:intarray_cast",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_intarray,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int *)intarray_cast(arg1);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_int, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_intarray_frompointer(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    int *arg1 = (int *) 0 ;
    intarray *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:intarray_frompointer",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_int,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (intarray *)intarray_frompointer(arg1);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_intarray, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject * intarray_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_intarray, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_fontSetObj_filename_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    fontSetObj *arg1 = (fontSetObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:fontSetObj_filename_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_fontSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->filename);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_fontSetObj_numfonts_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    fontSetObj *arg1 = (fontSetObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:fontSetObj_numfonts_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_fontSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numfonts);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_fontSetObj_fonts_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    fontSetObj *arg1 = (fontSetObj *) 0 ;
    hashTableObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:fontSetObj_fonts_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_fontSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (hashTableObj *)& ((arg1)->fonts);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_hashTableObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_fontSetObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    fontSetObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_fontSetObj")) goto fail;
    {
        result = (fontSetObj *)(fontSetObj *) calloc(1, sizeof(fontSetObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_fontSetObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_fontSetObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    fontSetObj *arg1 = (fontSetObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_fontSetObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_fontSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * fontSetObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_fontSetObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_outputFormatObj_name_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:outputFormatObj_name_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->name) free((char*)arg1->name);
        if (arg2) {
            arg1->name = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->name,arg2);
        } else {
            arg1->name = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_name_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_name_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->name);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_mimetype_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:outputFormatObj_mimetype_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->mimetype) free((char*)arg1->mimetype);
        if (arg2) {
            arg1->mimetype = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->mimetype,arg2);
        } else {
            arg1->mimetype = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_mimetype_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_mimetype_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->mimetype);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_driver_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:outputFormatObj_driver_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->driver) free((char*)arg1->driver);
        if (arg2) {
            arg1->driver = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->driver,arg2);
        } else {
            arg1->driver = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_driver_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_driver_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->driver);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_extension_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:outputFormatObj_extension_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->extension) free((char*)arg1->extension);
        if (arg2) {
            arg1->extension = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->extension,arg2);
        } else {
            arg1->extension = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_extension_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_extension_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->extension);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_renderer_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:outputFormatObj_renderer_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->renderer = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_renderer_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_renderer_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->renderer);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_imagemode_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:outputFormatObj_imagemode_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->imagemode = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_imagemode_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_imagemode_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->imagemode);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_transparent_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:outputFormatObj_transparent_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->transparent = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_transparent_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_transparent_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->transparent);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_bands_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:outputFormatObj_bands_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->bands = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_bands_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_bands_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->bands);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_numformatoptions_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:outputFormatObj_numformatoptions_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->numformatoptions = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_numformatoptions_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_numformatoptions_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numformatoptions);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_formatoptions_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char **arg2 = (char **) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:outputFormatObj_formatoptions_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_p_char,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->formatoptions = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_formatoptions_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char **result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_formatoptions_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char **) ((arg1)->formatoptions);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_p_char, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_refcount_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:outputFormatObj_refcount_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->refcount = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_refcount_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_refcount_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->refcount);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_inmapfile_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:outputFormatObj_inmapfile_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->inmapfile = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_inmapfile_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_inmapfile_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->inmapfile);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_outputFormatObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    char *arg1 ;
    char *arg2 = (char *) NULL ;
    outputFormatObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)"z|z:new_outputFormatObj",&arg1,&arg2)) goto fail;
    {
        result = (outputFormatObj *)new_outputFormatObj((char const *)arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_outputFormatObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_outputFormatObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_outputFormatObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        delete_outputFormatObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_setExtension(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:outputFormatObj_setExtension",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        outputFormatObj_setExtension(arg1,(char const *)arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_setMimetype(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:outputFormatObj_setMimetype",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        outputFormatObj_setMimetype(arg1,(char const *)arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_setOption(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *arg2 ;
    char *arg3 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Ozz:outputFormatObj_setOption",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        outputFormatObj_setOption(arg1,(char const *)arg2,(char const *)arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_validate(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:outputFormatObj_validate",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)outputFormatObj_validate(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_outputFormatObj_getOption(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    outputFormatObj *arg1 = (outputFormatObj *) 0 ;
    char *arg2 ;
    char *arg3 = (char *) "" ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz|z:outputFormatObj_getOption",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)outputFormatObj_getOption(arg1,(char const *)arg2,(char const *)arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject * outputFormatObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_outputFormatObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_queryMapObj_height_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:queryMapObj_height_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->height = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_height_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:queryMapObj_height_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->height);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_width_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:queryMapObj_width_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->width = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_width_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:queryMapObj_width_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->width);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_status_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:queryMapObj_status_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->status = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_status_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:queryMapObj_status_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->status);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_style_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:queryMapObj_style_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->style = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_style_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:queryMapObj_style_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->style);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_color_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:queryMapObj_color_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->color = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_queryMapObj_color_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:queryMapObj_color_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->color);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_queryMapObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_queryMapObj")) goto fail;
    {
        result = (queryMapObj *)(queryMapObj *) calloc(1, sizeof(queryMapObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_queryMapObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_queryMapObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    queryMapObj *arg1 = (queryMapObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_queryMapObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_queryMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * queryMapObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_queryMapObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_labelObj_font_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:labelObj_font_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->font) free((char*)arg1->font);
        if (arg2) {
            arg1->font = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->font,arg2);
        } else {
            arg1->font = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_font_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_font_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->font);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_type_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_type_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->type = (enum MS_FONT_TYPE)arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_type_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_type_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->type);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_color_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:labelObj_color_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->color = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_color_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_color_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->color);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_outlinecolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:labelObj_outlinecolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->outlinecolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_outlinecolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_outlinecolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->outlinecolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_shadowcolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:labelObj_shadowcolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->shadowcolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_shadowcolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_shadowcolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->shadowcolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_shadowsizex_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_shadowsizex_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->shadowsizex = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_shadowsizex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_shadowsizex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->shadowsizex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_shadowsizey_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_shadowsizey_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->shadowsizey = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_shadowsizey_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_shadowsizey_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->shadowsizey);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_backgroundcolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:labelObj_backgroundcolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->backgroundcolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_backgroundcolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_backgroundcolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->backgroundcolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_backgroundshadowcolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:labelObj_backgroundshadowcolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->backgroundshadowcolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_backgroundshadowcolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_backgroundshadowcolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->backgroundshadowcolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_backgroundshadowsizex_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_backgroundshadowsizex_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->backgroundshadowsizex = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_backgroundshadowsizex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_backgroundshadowsizex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->backgroundshadowsizex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_backgroundshadowsizey_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_backgroundshadowsizey_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->backgroundshadowsizey = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_backgroundshadowsizey_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_backgroundshadowsizey_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->backgroundshadowsizey);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_size_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_size_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->size = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_size_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_size_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->size);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_minsize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_minsize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minsize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_minsize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_minsize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->minsize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_maxsize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_maxsize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxsize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_maxsize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_maxsize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->maxsize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_position_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_position_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->position = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_position_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_position_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->position);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_offsetx_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_offsetx_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->offsetx = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_offsetx_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_offsetx_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->offsetx);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_offsety_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_offsety_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->offsety = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_offsety_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_offsety_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->offsety);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_angle_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:labelObj_angle_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->angle = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_angle_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_angle_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->angle);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_autoangle_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_autoangle_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->autoangle = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_autoangle_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_autoangle_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->autoangle);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_autofollow_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_autofollow_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->autofollow = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_autofollow_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_autofollow_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->autofollow);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_buffer_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_buffer_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->buffer = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_buffer_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_buffer_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->buffer);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_antialias_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_antialias_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->antialias = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_antialias_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_antialias_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->antialias);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_wrap_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    char arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oc:labelObj_wrap_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->wrap = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_wrap_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    char result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_wrap_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char) ((arg1)->wrap);
    
    resultobj = Py_BuildValue((char*)"c",result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_minfeaturesize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_minfeaturesize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minfeaturesize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_minfeaturesize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_minfeaturesize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->minfeaturesize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_autominfeaturesize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_autominfeaturesize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->autominfeaturesize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_autominfeaturesize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_autominfeaturesize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->autominfeaturesize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_mindistance_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_mindistance_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->mindistance = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_mindistance_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_mindistance_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->mindistance);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_partials_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_partials_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->partials = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_partials_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_partials_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->partials);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_force_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:labelObj_force_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->force = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_force_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_force_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->force);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_encoding_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:labelObj_encoding_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->encoding) free((char*)arg1->encoding);
        if (arg2) {
            arg1->encoding = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->encoding,arg2);
        } else {
            arg1->encoding = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelObj_encoding_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelObj_encoding_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->encoding);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_labelObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_labelObj")) goto fail;
    {
        result = (labelObj *)(labelObj *) calloc(1, sizeof(labelObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_labelObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelObj *arg1 = (labelObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_labelObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * labelObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_labelObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_webObj_log_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_log_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->log) free((char*)arg1->log);
        if (arg2) {
            arg1->log = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->log,arg2);
        } else {
            arg1->log = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_log_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_log_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->log);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_imagepath_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_imagepath_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->imagepath) free((char*)arg1->imagepath);
        if (arg2) {
            arg1->imagepath = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->imagepath,arg2);
        } else {
            arg1->imagepath = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_imagepath_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_imagepath_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->imagepath);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_imageurl_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_imageurl_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->imageurl) free((char*)arg1->imageurl);
        if (arg2) {
            arg1->imageurl = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->imageurl,arg2);
        } else {
            arg1->imageurl = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_imageurl_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_imageurl_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->imageurl);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_map_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    struct map_obj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_map_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (struct map_obj *) ((arg1)->map);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_map_obj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_template_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_template_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->template) free((char*)arg1->template);
        if (arg2) {
            arg1->template = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->template,arg2);
        } else {
            arg1->template = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_template_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_template_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->template);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_header_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_header_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->header) free((char*)arg1->header);
        if (arg2) {
            arg1->header = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->header,arg2);
        } else {
            arg1->header = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_header_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_header_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->header);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_footer_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_footer_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->footer) free((char*)arg1->footer);
        if (arg2) {
            arg1->footer = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->footer,arg2);
        } else {
            arg1->footer = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_footer_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_footer_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->footer);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_empty_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_empty_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->empty) free((char*)arg1->empty);
        if (arg2) {
            arg1->empty = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->empty,arg2);
        } else {
            arg1->empty = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_empty_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_empty_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->empty);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_error_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_error_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->error) free((char*)arg1->error);
        if (arg2) {
            arg1->error = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->error,arg2);
        } else {
            arg1->error = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_error_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_error_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->error);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_extent_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    rectObj *arg2 = (rectObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:webObj_extent_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_rectObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->extent = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_extent_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    rectObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_extent_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (rectObj *)& ((arg1)->extent);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_rectObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_minscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:webObj_minscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_minscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_minscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->minscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_maxscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:webObj_maxscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_maxscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_maxscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->maxscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_mintemplate_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_mintemplate_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->mintemplate) free((char*)arg1->mintemplate);
        if (arg2) {
            arg1->mintemplate = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->mintemplate,arg2);
        } else {
            arg1->mintemplate = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_mintemplate_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_mintemplate_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->mintemplate);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_maxtemplate_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_maxtemplate_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->maxtemplate) free((char*)arg1->maxtemplate);
        if (arg2) {
            arg1->maxtemplate = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->maxtemplate,arg2);
        } else {
            arg1->maxtemplate = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_maxtemplate_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_maxtemplate_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->maxtemplate);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_queryformat_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_queryformat_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->queryformat) free((char*)arg1->queryformat);
        if (arg2) {
            arg1->queryformat = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->queryformat,arg2);
        } else {
            arg1->queryformat = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_queryformat_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_queryformat_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->queryformat);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_legendformat_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_legendformat_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->legendformat) free((char*)arg1->legendformat);
        if (arg2) {
            arg1->legendformat = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->legendformat,arg2);
        } else {
            arg1->legendformat = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_legendformat_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_legendformat_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->legendformat);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_browseformat_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:webObj_browseformat_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->browseformat) free((char*)arg1->browseformat);
        if (arg2) {
            arg1->browseformat = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->browseformat,arg2);
        } else {
            arg1->browseformat = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_browseformat_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_browseformat_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->browseformat);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_webObj_metadata_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    hashTableObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:webObj_metadata_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (hashTableObj *)& ((arg1)->metadata);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_hashTableObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_webObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_webObj")) goto fail;
    {
        result = (webObj *)new_webObj();
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_webObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_webObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    webObj *arg1 = (webObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_webObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_webObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        delete_webObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * webObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_webObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_styleObj_color_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:styleObj_color_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->color = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_color_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_color_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->color);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_backgroundcolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:styleObj_backgroundcolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->backgroundcolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_backgroundcolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_backgroundcolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->backgroundcolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_outlinecolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:styleObj_outlinecolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->outlinecolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_outlinecolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_outlinecolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->outlinecolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_mincolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:styleObj_mincolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->mincolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_mincolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_mincolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->mincolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_maxcolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:styleObj_maxcolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxcolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_maxcolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_maxcolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->maxcolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_minvalue_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:styleObj_minvalue_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minvalue = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_minvalue_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_minvalue_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->minvalue);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_maxvalue_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:styleObj_maxvalue_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxvalue = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_maxvalue_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_maxvalue_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->maxvalue);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_rangeitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:styleObj_rangeitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->rangeitem) free((char*)arg1->rangeitem);
        if (arg2) {
            arg1->rangeitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->rangeitem,arg2);
        } else {
            arg1->rangeitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_rangeitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_rangeitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->rangeitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_rangeitemindex_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_rangeitemindex_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->rangeitemindex = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_rangeitemindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_rangeitemindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->rangeitemindex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_symbol_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_symbol_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->symbol = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_symbol_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_symbol_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->symbol);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_symbolname_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:styleObj_symbolname_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->symbolname) free((char*)arg1->symbolname);
        if (arg2) {
            arg1->symbolname = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->symbolname,arg2);
        } else {
            arg1->symbolname = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_symbolname_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_symbolname_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->symbolname);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_size_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_size_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->size = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_size_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_size_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->size);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_minsize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_minsize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minsize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_minsize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_minsize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->minsize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_maxsize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_maxsize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxsize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_maxsize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_maxsize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->maxsize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_width_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_width_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->width = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_width_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_width_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->width);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_minwidth_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_minwidth_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minwidth = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_minwidth_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_minwidth_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->minwidth);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_maxwidth_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_maxwidth_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxwidth = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_maxwidth_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_maxwidth_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->maxwidth);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_offsetx_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_offsetx_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->offsetx = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_offsetx_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_offsetx_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->offsetx);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_offsety_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_offsety_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->offsety = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_offsety_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_offsety_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->offsety);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_angle_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:styleObj_angle_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->angle = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_angle_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_angle_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->angle);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_antialias_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:styleObj_antialias_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->antialias = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_antialias_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_antialias_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->antialias);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_angleitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:styleObj_angleitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->angleitem) free((char*)arg1->angleitem);
        if (arg2) {
            arg1->angleitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->angleitem,arg2);
        } else {
            arg1->angleitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_angleitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_angleitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->angleitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_sizeitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:styleObj_sizeitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->sizeitem) free((char*)arg1->sizeitem);
        if (arg2) {
            arg1->sizeitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->sizeitem,arg2);
        } else {
            arg1->sizeitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_sizeitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_sizeitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->sizeitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_styleObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) NULL ;
    styleObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"|O:new_styleObj",&obj0)) goto fail;
    if (obj0) {
        if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    }
    {
        result = (styleObj *)new_styleObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_styleObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_styleObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_styleObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        delete_styleObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_clone(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    styleObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:styleObj_clone",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (styleObj *)styleObj_clone(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_styleObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_styleObj_setSymbolByName(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    styleObj *arg1 = (styleObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    char *arg3 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOz:styleObj_setSymbolByName",&obj0,&obj1,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)styleObj_setSymbolByName(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject * styleObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_styleObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_classObj_status_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:classObj_status_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->status = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_status_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_status_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->status);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_numstyles_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:classObj_numstyles_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->numstyles = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_numstyles_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_numstyles_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numstyles);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_label_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    labelObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_label_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (labelObj *)& ((arg1)->label);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_name_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:classObj_name_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->name) free((char*)arg1->name);
        if (arg2) {
            arg1->name = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->name,arg2);
        } else {
            arg1->name = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_name_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_name_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->name);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_title_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:classObj_title_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->title) free((char*)arg1->title);
        if (arg2) {
            arg1->title = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->title,arg2);
        } else {
            arg1->title = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_title_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_title_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->title);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_template_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:classObj_template_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->template) free((char*)arg1->template);
        if (arg2) {
            arg1->template = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->template,arg2);
        } else {
            arg1->template = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_template_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_template_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->template);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_type_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:classObj_type_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->type = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_type_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_type_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->type);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_metadata_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    hashTableObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_metadata_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (hashTableObj *)& ((arg1)->metadata);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_hashTableObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_minscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:classObj_minscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_minscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_minscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->minscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_maxscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:classObj_maxscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_maxscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_maxscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->maxscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_layer_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    struct layer_obj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_layer_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (struct layer_obj *) ((arg1)->layer);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_layer_obj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_debug_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:classObj_debug_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->debug = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_debug_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_debug_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->debug);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_keyimage_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:classObj_keyimage_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->keyimage) free((char*)arg1->keyimage);
        if (arg2) {
            arg1->keyimage = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->keyimage,arg2);
        } else {
            arg1->keyimage = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_keyimage_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_keyimage_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->keyimage);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_classObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) NULL ;
    classObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"|O:new_classObj",&obj0)) goto fail;
    if (obj0) {
        if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    }
    {
        result = (classObj *)new_classObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_classObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_classObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_classObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        delete_classObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_clone(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    classObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_clone",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (classObj *)classObj_clone(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_classObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_setExpression(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:classObj_setExpression",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)classObj_setExpression(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_getExpressionString(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_getExpressionString",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)classObj_getExpressionString(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_setText(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:classObj_setText",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)classObj_setText(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_getTextString(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_getTextString",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)classObj_getTextString(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_getMetaData(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:classObj_getMetaData",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)classObj_getMetaData(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_setMetaData(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    char *arg3 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Ozz:classObj_setMetaData",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)classObj_setMetaData(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_getFirstMetaDataKey(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:classObj_getFirstMetaDataKey",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)classObj_getFirstMetaDataKey(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_getNextMetaDataKey(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    char *arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:classObj_getNextMetaDataKey",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)classObj_getNextMetaDataKey(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_drawLegendIcon(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    layerObj *arg3 = (layerObj *) 0 ;
    int arg4 ;
    int arg5 ;
    imageObj *arg6 = (imageObj *) 0 ;
    int arg7 ;
    int arg8 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj5 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOOiiOii:classObj_drawLegendIcon",&obj0,&obj1,&obj2,&arg4,&arg5,&obj5,&arg7,&arg8)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj2,(void **) &arg3, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj5,(void **) &arg6, SWIGTYPE_p_imageObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)classObj_drawLegendIcon(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_createLegendIcon(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    layerObj *arg3 = (layerObj *) 0 ;
    int arg4 ;
    int arg5 ;
    imageObj *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOOii:classObj_createLegendIcon",&obj0,&obj1,&obj2,&arg4,&arg5)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj2,(void **) &arg3, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (imageObj *)classObj_createLegendIcon(arg1,arg2,arg3,arg4,arg5);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_imageObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_getStyle(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int arg2 ;
    styleObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:classObj_getStyle",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (styleObj *)classObj_getStyle(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_styleObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_insertStyle(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    styleObj *arg2 = (styleObj *) 0 ;
    int arg3 = (int) -1 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO|i:classObj_insertStyle",&obj0,&obj1,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_styleObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)classObj_insertStyle(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_removeStyle(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int arg2 ;
    styleObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:classObj_removeStyle",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (styleObj *)classObj_removeStyle(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_styleObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_moveStyleUp(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:classObj_moveStyleUp",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)classObj_moveStyleUp(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_classObj_moveStyleDown(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    classObj *arg1 = (classObj *) 0 ;
    int arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:classObj_moveStyleDown",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)classObj_moveStyleDown(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject * classObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_classObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_labelCacheMemberObj_text_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_text_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->text);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_featuresize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_featuresize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->featuresize);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_styles_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    styleObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_styles_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (styleObj *) ((arg1)->styles);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_styleObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_numstyles_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_numstyles_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numstyles);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_label_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    labelObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_label_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (labelObj *)& ((arg1)->label);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_layerindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_layerindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->layerindex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_classindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_classindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->classindex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_tileindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_tileindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->tileindex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_shapeindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_shapeindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->shapeindex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_point_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    pointObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_point_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (pointObj *)& ((arg1)->point);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_pointObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_poly_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    shapeObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_poly_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (shapeObj *) ((arg1)->poly);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_shapeObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_status_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_status_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->status);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheMemberObj_labelpath_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    labelPathObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheMemberObj_labelpath_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (labelPathObj *) ((arg1)->labelpath);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelPathObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_labelCacheMemberObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_labelCacheMemberObj")) goto fail;
    {
        result = (labelCacheMemberObj *)(labelCacheMemberObj *) calloc(1, sizeof(labelCacheMemberObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelCacheMemberObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_labelCacheMemberObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheMemberObj *arg1 = (labelCacheMemberObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_labelCacheMemberObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * labelCacheMemberObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_labelCacheMemberObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_markerCacheMemberObj_id_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    markerCacheMemberObj *arg1 = (markerCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:markerCacheMemberObj_id_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_markerCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->id);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_markerCacheMemberObj_poly_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    markerCacheMemberObj *arg1 = (markerCacheMemberObj *) 0 ;
    shapeObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:markerCacheMemberObj_poly_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_markerCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (shapeObj *) ((arg1)->poly);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_shapeObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_markerCacheMemberObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    markerCacheMemberObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_markerCacheMemberObj")) goto fail;
    {
        result = (markerCacheMemberObj *)(markerCacheMemberObj *) calloc(1, sizeof(markerCacheMemberObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_markerCacheMemberObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_markerCacheMemberObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    markerCacheMemberObj *arg1 = (markerCacheMemberObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_markerCacheMemberObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_markerCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * markerCacheMemberObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_markerCacheMemberObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_labelCacheObj_labels_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *arg1 = (labelCacheObj *) 0 ;
    labelCacheMemberObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheObj_labels_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (labelCacheMemberObj *) ((arg1)->labels);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelCacheMemberObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheObj_numlabels_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *arg1 = (labelCacheObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheObj_numlabels_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numlabels);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheObj_cachesize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *arg1 = (labelCacheObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheObj_cachesize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->cachesize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheObj_markers_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *arg1 = (labelCacheObj *) 0 ;
    markerCacheMemberObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheObj_markers_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (markerCacheMemberObj *) ((arg1)->markers);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_markerCacheMemberObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheObj_nummarkers_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *arg1 = (labelCacheObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheObj_nummarkers_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->nummarkers);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheObj_markercachesize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *arg1 = (labelCacheObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheObj_markercachesize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->markercachesize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_labelCacheObj_freeCache(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *arg1 = (labelCacheObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:labelCacheObj_freeCache",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        labelCacheObj_freeCache(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_labelCacheObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_labelCacheObj")) goto fail;
    {
        result = (labelCacheObj *)(labelCacheObj *) calloc(1, sizeof(labelCacheObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelCacheObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_labelCacheObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    labelCacheObj *arg1 = (labelCacheObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_labelCacheObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_labelCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * labelCacheObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_labelCacheObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_resultCacheMemberObj_shapeindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheMemberObj *arg1 = (resultCacheMemberObj *) 0 ;
    long result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:resultCacheMemberObj_shapeindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_resultCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (long) ((arg1)->shapeindex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_resultCacheMemberObj_tileindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheMemberObj *arg1 = (resultCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:resultCacheMemberObj_tileindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_resultCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->tileindex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_resultCacheMemberObj_classindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheMemberObj *arg1 = (resultCacheMemberObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:resultCacheMemberObj_classindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_resultCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->classindex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_resultCacheMemberObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheMemberObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_resultCacheMemberObj")) goto fail;
    {
        result = (resultCacheMemberObj *)(resultCacheMemberObj *) calloc(1, sizeof(resultCacheMemberObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_resultCacheMemberObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_resultCacheMemberObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheMemberObj *arg1 = (resultCacheMemberObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_resultCacheMemberObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_resultCacheMemberObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * resultCacheMemberObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_resultCacheMemberObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_resultCacheObj_numresults_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheObj *arg1 = (resultCacheObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:resultCacheObj_numresults_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_resultCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numresults);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_resultCacheObj_bounds_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheObj *arg1 = (resultCacheObj *) 0 ;
    rectObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:resultCacheObj_bounds_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_resultCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (rectObj *)& ((arg1)->bounds);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_rectObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_resultCacheObj_getResult(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheObj *arg1 = (resultCacheObj *) 0 ;
    int arg2 ;
    resultCacheMemberObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:resultCacheObj_getResult",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_resultCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (resultCacheMemberObj *)resultCacheObj_getResult(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_resultCacheMemberObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_resultCacheObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_resultCacheObj")) goto fail;
    {
        result = (resultCacheObj *)(resultCacheObj *) calloc(1, sizeof(resultCacheObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_resultCacheObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_resultCacheObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    resultCacheObj *arg1 = (resultCacheObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_resultCacheObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_resultCacheObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * resultCacheObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_resultCacheObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_symbolSetObj_filename_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:symbolSetObj_filename_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->filename) free((char*)arg1->filename);
        if (arg2) {
            arg1->filename = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->filename,arg2);
        } else {
            arg1->filename = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_filename_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:symbolSetObj_filename_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->filename);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_imagecachesize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:symbolSetObj_imagecachesize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->imagecachesize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_imagecachesize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:symbolSetObj_imagecachesize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->imagecachesize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_numsymbols_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:symbolSetObj_numsymbols_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numsymbols);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_symbol_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    symbolObj *arg2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:symbolSetObj_symbol_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_symbolObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        int ii;
        symbolObj *b = (symbolObj *) arg1->symbol;
        for (ii = 0; ii < MS_MAXSYMBOLS; ii++) b[ii] = *((symbolObj *) arg2 + ii);
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_symbol_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    symbolObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:symbolSetObj_symbol_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (symbolObj *)(symbolObj *) ((arg1)->symbol);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_symbolObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_symbolSetObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    char *arg1 = (char *) NULL ;
    symbolSetObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)"|z:new_symbolSetObj",&arg1)) goto fail;
    {
        result = (symbolSetObj *)new_symbolSetObj((char const *)arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_symbolSetObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_symbolSetObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_symbolSetObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        delete_symbolSetObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_getSymbol(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    int arg2 ;
    symbolObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:symbolSetObj_getSymbol",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (symbolObj *)symbolSetObj_getSymbol(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_symbolObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_getSymbolByName(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    char *arg2 ;
    symbolObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:symbolSetObj_getSymbolByName",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (symbolObj *)symbolSetObj_getSymbolByName(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_symbolObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_index(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:symbolSetObj_index",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)symbolSetObj_index(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_appendSymbol(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    symbolObj *arg2 = (symbolObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:symbolSetObj_appendSymbol",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_symbolObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)symbolSetObj_appendSymbol(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_removeSymbol(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    int arg2 ;
    symbolObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:symbolSetObj_removeSymbol",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (symbolObj *)symbolSetObj_removeSymbol(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_symbolObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_symbolSetObj_save(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    symbolSetObj *arg1 = (symbolSetObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:symbolSetObj_save",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_symbolSetObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)symbolSetObj_save(arg1,(char const *)arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject * symbolSetObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_symbolSetObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_referenceMapObj_extent_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    rectObj *arg2 = (rectObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:referenceMapObj_extent_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_rectObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->extent = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_extent_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    rectObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_extent_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (rectObj *)& ((arg1)->extent);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_rectObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_height_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:referenceMapObj_height_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->height = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_height_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_height_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->height);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_width_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:referenceMapObj_width_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->width = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_width_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_width_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->width);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_color_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:referenceMapObj_color_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->color = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_color_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_color_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->color);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_outlinecolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:referenceMapObj_outlinecolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->outlinecolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_outlinecolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_outlinecolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->outlinecolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_image_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:referenceMapObj_image_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->image) free((char*)arg1->image);
        if (arg2) {
            arg1->image = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->image,arg2);
        } else {
            arg1->image = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_image_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_image_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->image);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_status_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:referenceMapObj_status_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->status = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_status_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_status_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->status);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_marker_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:referenceMapObj_marker_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->marker = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_marker_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_marker_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->marker);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_markername_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:referenceMapObj_markername_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->markername) free((char*)arg1->markername);
        if (arg2) {
            arg1->markername = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->markername,arg2);
        } else {
            arg1->markername = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_markername_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_markername_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->markername);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_markersize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:referenceMapObj_markersize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->markersize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_markersize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_markersize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->markersize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_minboxsize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:referenceMapObj_minboxsize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minboxsize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_minboxsize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_minboxsize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->minboxsize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_maxboxsize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:referenceMapObj_maxboxsize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxboxsize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_maxboxsize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_maxboxsize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->maxboxsize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_referenceMapObj_map_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    struct map_obj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:referenceMapObj_map_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (struct map_obj *) ((arg1)->map);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_map_obj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_referenceMapObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_referenceMapObj")) goto fail;
    {
        result = (referenceMapObj *)(referenceMapObj *) calloc(1, sizeof(referenceMapObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_referenceMapObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_referenceMapObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    referenceMapObj *arg1 = (referenceMapObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_referenceMapObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_referenceMapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * referenceMapObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_referenceMapObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_scalebarObj_imagecolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:scalebarObj_imagecolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->imagecolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_imagecolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_imagecolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->imagecolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_height_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:scalebarObj_height_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->height = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_height_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_height_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->height);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_width_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:scalebarObj_width_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->width = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_width_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_width_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->width);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_style_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:scalebarObj_style_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->style = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_style_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_style_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->style);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_intervals_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:scalebarObj_intervals_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->intervals = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_intervals_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_intervals_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->intervals);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_label_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    labelObj *arg2 = (labelObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:scalebarObj_label_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_labelObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->label = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_label_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    labelObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_label_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (labelObj *)& ((arg1)->label);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_color_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:scalebarObj_color_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->color = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_color_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_color_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->color);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_backgroundcolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:scalebarObj_backgroundcolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->backgroundcolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_backgroundcolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_backgroundcolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->backgroundcolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_outlinecolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:scalebarObj_outlinecolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->outlinecolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_outlinecolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_outlinecolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->outlinecolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_units_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:scalebarObj_units_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->units = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_units_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_units_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->units);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_status_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:scalebarObj_status_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->status = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_status_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_status_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->status);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_position_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:scalebarObj_position_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->position = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_position_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_position_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->position);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_postlabelcache_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:scalebarObj_postlabelcache_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->postlabelcache = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_scalebarObj_postlabelcache_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:scalebarObj_postlabelcache_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->postlabelcache);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_scalebarObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_scalebarObj")) goto fail;
    {
        result = (scalebarObj *)(scalebarObj *) calloc(1, sizeof(scalebarObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_scalebarObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_scalebarObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    scalebarObj *arg1 = (scalebarObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_scalebarObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_scalebarObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * scalebarObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_scalebarObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_legendObj_imagecolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:legendObj_imagecolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->imagecolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_imagecolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_imagecolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->imagecolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_label_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    labelObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_label_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (labelObj *)& ((arg1)->label);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_keysizex_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_keysizex_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->keysizex = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_keysizex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_keysizex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->keysizex);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_keysizey_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_keysizey_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->keysizey = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_keysizey_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_keysizey_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->keysizey);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_keyspacingx_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_keyspacingx_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->keyspacingx = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_keyspacingx_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_keyspacingx_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->keyspacingx);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_keyspacingy_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_keyspacingy_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->keyspacingy = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_keyspacingy_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_keyspacingy_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->keyspacingy);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_outlinecolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:legendObj_outlinecolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->outlinecolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_outlinecolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_outlinecolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->outlinecolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_status_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_status_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->status = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_status_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_status_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->status);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_height_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_height_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->height = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_height_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_height_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->height);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_width_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_width_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->width = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_width_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_width_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->width);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_position_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_position_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->position = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_position_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_position_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->position);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_postlabelcache_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:legendObj_postlabelcache_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->postlabelcache = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_postlabelcache_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_postlabelcache_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->postlabelcache);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_template_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:legendObj_template_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->template) free((char*)arg1->template);
        if (arg2) {
            arg1->template = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->template,arg2);
        } else {
            arg1->template = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_template_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_template_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->template);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_legendObj_map_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    struct map_obj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:legendObj_map_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (struct map_obj *) ((arg1)->map);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_map_obj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_legendObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)":new_legendObj")) goto fail;
    {
        result = (legendObj *)(legendObj *) calloc(1, sizeof(legendObj));
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_legendObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_legendObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    legendObj *arg1 = (legendObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_legendObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_legendObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        free((char *) arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * legendObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_legendObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_layerObj_classitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_classitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->classitem) free((char*)arg1->classitem);
        if (arg2) {
            arg1->classitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->classitem,arg2);
        } else {
            arg1->classitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_classitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_classitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->classitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_numclasses_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_numclasses_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numclasses);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_index_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_index_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->index);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_map_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    struct map_obj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_map_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (struct map_obj *) ((arg1)->map);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_map_obj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_header_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_header_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->header) free((char*)arg1->header);
        if (arg2) {
            arg1->header = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->header,arg2);
        } else {
            arg1->header = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_header_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_header_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->header);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_footer_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_footer_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->footer) free((char*)arg1->footer);
        if (arg2) {
            arg1->footer = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->footer,arg2);
        } else {
            arg1->footer = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_footer_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_footer_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->footer);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_template_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_template_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->template) free((char*)arg1->template);
        if (arg2) {
            arg1->template = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->template,arg2);
        } else {
            arg1->template = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_template_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_template_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->template);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_name_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_name_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->name) free((char*)arg1->name);
        if (arg2) {
            arg1->name = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->name,arg2);
        } else {
            arg1->name = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_name_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_name_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->name);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_group_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_group_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->group) free((char*)arg1->group);
        if (arg2) {
            arg1->group = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->group,arg2);
        } else {
            arg1->group = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_group_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_group_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->group);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_status_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_status_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->status = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_status_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_status_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->status);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_data_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_data_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->data) free((char*)arg1->data);
        if (arg2) {
            arg1->data = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->data,arg2);
        } else {
            arg1->data = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_data_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_data_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->data);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_type_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_type_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->type = (enum MS_LAYER_TYPE)arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_type_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_type_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->type);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_tolerance_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:layerObj_tolerance_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->tolerance = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_tolerance_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_tolerance_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->tolerance);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_toleranceunits_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_toleranceunits_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->toleranceunits = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_toleranceunits_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_toleranceunits_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->toleranceunits);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_symbolscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:layerObj_symbolscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->symbolscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_symbolscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_symbolscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->symbolscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_minscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:layerObj_minscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->minscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_minscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_minscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->minscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_maxscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:layerObj_maxscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_maxscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_maxscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->maxscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelminscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:layerObj_labelminscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->labelminscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelminscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_labelminscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->labelminscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelmaxscale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:layerObj_labelmaxscale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->labelmaxscale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelmaxscale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_labelmaxscale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->labelmaxscale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_sizeunits_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_sizeunits_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->sizeunits = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_sizeunits_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_sizeunits_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->sizeunits);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_maxfeatures_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_maxfeatures_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxfeatures = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_maxfeatures_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_maxfeatures_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->maxfeatures);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_offsite_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:layerObj_offsite_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->offsite = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_offsite_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_offsite_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->offsite);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_transform_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_transform_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->transform = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_transform_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_transform_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->transform);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelcache_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_labelcache_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->labelcache = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelcache_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_labelcache_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->labelcache);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_postlabelcache_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_postlabelcache_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->postlabelcache = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_postlabelcache_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_postlabelcache_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->postlabelcache);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_labelitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->labelitem) free((char*)arg1->labelitem);
        if (arg2) {
            arg1->labelitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->labelitem,arg2);
        } else {
            arg1->labelitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_labelitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->labelitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelsizeitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_labelsizeitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->labelsizeitem) free((char*)arg1->labelsizeitem);
        if (arg2) {
            arg1->labelsizeitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->labelsizeitem,arg2);
        } else {
            arg1->labelsizeitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelsizeitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_labelsizeitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->labelsizeitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelangleitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_labelangleitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->labelangleitem) free((char*)arg1->labelangleitem);
        if (arg2) {
            arg1->labelangleitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->labelangleitem,arg2);
        } else {
            arg1->labelangleitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelangleitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_labelangleitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->labelangleitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_tileitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_tileitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->tileitem) free((char*)arg1->tileitem);
        if (arg2) {
            arg1->tileitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->tileitem,arg2);
        } else {
            arg1->tileitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_tileitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_tileitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->tileitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_tileindex_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_tileindex_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->tileindex) free((char*)arg1->tileindex);
        if (arg2) {
            arg1->tileindex = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->tileindex,arg2);
        } else {
            arg1->tileindex = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_tileindex_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_tileindex_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->tileindex);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_units_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_units_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->units = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_units_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_units_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->units);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_connection_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_connection_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->connection) free((char*)arg1->connection);
        if (arg2) {
            arg1->connection = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->connection,arg2);
        } else {
            arg1->connection = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_connection_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_connection_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->connection);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_plugin_library_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_plugin_library_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->plugin_library) free((char*)arg1->plugin_library);
        if (arg2) {
            arg1->plugin_library = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->plugin_library,arg2);
        } else {
            arg1->plugin_library = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_plugin_library_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_plugin_library_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->plugin_library);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_plugin_library_original_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_plugin_library_original_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->plugin_library_original) free((char*)arg1->plugin_library_original);
        if (arg2) {
            arg1->plugin_library_original = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->plugin_library_original,arg2);
        } else {
            arg1->plugin_library_original = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_plugin_library_original_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_plugin_library_original_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->plugin_library_original);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_connectiontype_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_connectiontype_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->connectiontype = (enum MS_CONNECTION_TYPE)arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_connectiontype_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_connectiontype_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->connectiontype);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_numitems_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_numitems_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numitems);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_bandsitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_bandsitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->bandsitem) free((char*)arg1->bandsitem);
        if (arg2) {
            arg1->bandsitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->bandsitem,arg2);
        } else {
            arg1->bandsitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_bandsitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_bandsitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->bandsitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_filteritem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_filteritem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->filteritem) free((char*)arg1->filteritem);
        if (arg2) {
            arg1->filteritem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->filteritem,arg2);
        } else {
            arg1->filteritem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_filteritem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_filteritem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->filteritem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_styleitem_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_styleitem_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->styleitem) free((char*)arg1->styleitem);
        if (arg2) {
            arg1->styleitem = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->styleitem,arg2);
        } else {
            arg1->styleitem = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_styleitem_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_styleitem_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->styleitem);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_requires_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_requires_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->requires) free((char*)arg1->requires);
        if (arg2) {
            arg1->requires = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->requires,arg2);
        } else {
            arg1->requires = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_requires_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_requires_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->requires);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelrequires_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_labelrequires_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->labelrequires) free((char*)arg1->labelrequires);
        if (arg2) {
            arg1->labelrequires = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->labelrequires,arg2);
        } else {
            arg1->labelrequires = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_labelrequires_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_labelrequires_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->labelrequires);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_metadata_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    hashTableObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_metadata_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (hashTableObj *)& ((arg1)->metadata);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_hashTableObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_transparency_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_transparency_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->transparency = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_transparency_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_transparency_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->transparency);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_dump_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_dump_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->dump = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_dump_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_dump_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->dump);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_debug_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_debug_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->debug = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_debug_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_debug_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->debug);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_extent_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    rectObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_extent_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (rectObj *)& ((arg1)->extent);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_rectObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_numprocessing_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_numprocessing_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numprocessing);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_numjoins_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_numjoins_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numjoins);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_layerObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) NULL ;
    layerObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"|O:new_layerObj",&obj0)) goto fail;
    if (obj0) {
        if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    }
    {
        result = (layerObj *)new_layerObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_layerObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_layerObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_layerObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        delete_layerObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_clone(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    layerObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_clone",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (layerObj *)layerObj_clone(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_layerObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_insertClass(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    classObj *arg2 = (classObj *) 0 ;
    int arg3 = (int) -1 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO|i:layerObj_insertClass",&obj0,&obj1,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_classObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_insertClass(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_removeClass(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    classObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_removeClass",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (classObj *)layerObj_removeClass(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_classObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_open(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_open",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_open(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_whichShapes(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    rectObj arg2 ;
    int result;
    rectObj *argp2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:layerObj_whichShapes",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &argp2, SWIGTYPE_p_rectObj,SWIG_POINTER_EXCEPTION) == -1)) SWIG_fail;
    arg2 = *argp2; 
    {
        result = (int)layerObj_whichShapes(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_nextShape(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    shapeObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_nextShape",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (shapeObj *)layerObj_nextShape(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_shapeObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_close(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_close",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        layerObj_close(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getFeature(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    int arg3 = (int) -1 ;
    shapeObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi|i:layerObj_getFeature",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (shapeObj *)layerObj_getFeature(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_shapeObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getShape(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    shapeObj *arg2 = (shapeObj *) 0 ;
    int arg3 ;
    int arg4 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOii:layerObj_getShape",&obj0,&obj1,&arg3,&arg4)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_shapeObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_getShape(arg1,arg2,arg3,arg4);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getNumResults(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_getNumResults",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_getNumResults(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getResult(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    resultCacheMemberObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_getResult",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (resultCacheMemberObj *)layerObj_getResult(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_resultCacheMemberObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getClass(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    classObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_getClass",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (classObj *)layerObj_getClass(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_classObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getItem(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_getItem",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_getItem(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_draw(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    imageObj *arg3 = (imageObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOO:layerObj_draw",&obj0,&obj1,&obj2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj2,(void **) &arg3, SWIGTYPE_p_imageObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_draw(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_drawQuery(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    imageObj *arg3 = (imageObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOO:layerObj_drawQuery",&obj0,&obj1,&obj2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj2,(void **) &arg3, SWIGTYPE_p_imageObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_drawQuery(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_queryByAttributes(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    char *arg3 ;
    char *arg4 ;
    int arg5 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOzzi:layerObj_queryByAttributes",&obj0,&obj1,&arg3,&arg4,&arg5)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_queryByAttributes(arg1,arg2,arg3,arg4,arg5);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_queryByPoint(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    pointObj *arg3 = (pointObj *) 0 ;
    int arg4 ;
    double arg5 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOOid:layerObj_queryByPoint",&obj0,&obj1,&obj2,&arg4,&arg5)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj2,(void **) &arg3, SWIGTYPE_p_pointObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_queryByPoint(arg1,arg2,arg3,arg4,arg5);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_queryByRect(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    rectObj arg3 ;
    int result;
    rectObj *argp3 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOO:layerObj_queryByRect",&obj0,&obj1,&obj2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj2,(void **) &argp3, SWIGTYPE_p_rectObj,SWIG_POINTER_EXCEPTION) == -1)) SWIG_fail;
    arg3 = *argp3; 
    {
        result = (int)layerObj_queryByRect(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_queryByFeatures(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    int arg3 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOi:layerObj_queryByFeatures",&obj0,&obj1,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_queryByFeatures(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_queryByShape(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    shapeObj *arg3 = (shapeObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOO:layerObj_queryByShape",&obj0,&obj1,&obj2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj2,(void **) &arg3, SWIGTYPE_p_shapeObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_queryByShape(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_queryByIndex(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    int arg3 ;
    int arg4 ;
    int arg5 = (int) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOii|i:layerObj_queryByIndex",&obj0,&obj1,&arg3,&arg4,&arg5)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_queryByIndex(arg1,arg2,arg3,arg4,arg5);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getResults(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    resultCacheObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_getResults",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (resultCacheObj *)layerObj_getResults(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_resultCacheObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_setFilter(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_setFilter",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_setFilter(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getFilterString(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_getFilterString",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_getFilterString(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_setWKTProjection(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_setWKTProjection",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_setWKTProjection(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getProjection(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_getProjection",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_getProjection(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_setProjection(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_setProjection",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_setProjection(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_addFeature(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    shapeObj *arg2 = (shapeObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:layerObj_addFeature",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_shapeObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_addFeature(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getNumFeatures(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_getNumFeatures",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_getNumFeatures(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getExtent(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    rectObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_getExtent",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (rectObj *)layerObj_getExtent(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_rectObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_setExtent(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    double arg2 = (double) -1.0 ;
    double arg3 = (double) -1.0 ;
    double arg4 = (double) -1.0 ;
    double arg5 = (double) -1.0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O|dddd:layerObj_setExtent",&obj0,&arg2,&arg3,&arg4,&arg5)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_setExtent(arg1,arg2,arg3,arg4,arg5);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getMetaData(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_getMetaData",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_getMetaData(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_setMetaData(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    char *arg3 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Ozz:layerObj_setMetaData",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_setMetaData(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_removeMetaData(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_removeMetaData",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_removeMetaData(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getFirstMetaDataKey(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_getFirstMetaDataKey",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_getFirstMetaDataKey(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getNextMetaDataKey(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_getNextMetaDataKey",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_getNextMetaDataKey(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getWMSFeatureInfoURL(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    mapObj *arg2 = (mapObj *) 0 ;
    int arg3 ;
    int arg4 ;
    int arg5 ;
    char *arg6 ;
    char *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOiiiz:layerObj_getWMSFeatureInfoURL",&obj0,&obj1,&arg3,&arg4,&arg5,&arg6)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_getWMSFeatureInfoURL(arg1,arg2,arg3,arg4,arg5,arg6);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_executeWFSGetFeature(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    layerObj *arg2 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:layerObj_executeWFSGetFeature",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_executeWFSGetFeature(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_applySLD(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    char *arg3 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Ozz:layerObj_applySLD",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_applySLD(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_applySLDURL(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    char *arg3 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Ozz:layerObj_applySLDURL",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_applySLDURL(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_generateSLD(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_generateSLD",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_generateSLD(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_isVisible(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_isVisible",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_isVisible(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_moveClassUp(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_moveClassUp",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_moveClassUp(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_moveClassDown(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_moveClassDown",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_moveClassDown(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_setProcessingKey(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    char *arg3 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Ozz:layerObj_setProcessingKey",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        layerObj_setProcessingKey(arg1,(char const *)arg2,(char const *)arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_setProcessing(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_setProcessing",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        layerObj_setProcessing(arg1,(char const *)arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_addProcessing(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:layerObj_addProcessing",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        layerObj_addProcessing(arg1,(char const *)arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_getProcessing(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:layerObj_getProcessing",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)layerObj_getProcessing(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_layerObj_clearProcessing(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    layerObj *arg1 = (layerObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:layerObj_clearProcessing",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)layerObj_clearProcessing(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject * layerObj_swigregister(PyObject *self, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_layerObj, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_mapObj_name_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_name_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->name) free((char*)arg1->name);
        if (arg2) {
            arg1->name = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->name,arg2);
        } else {
            arg1->name = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_name_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_name_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->name);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_status_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_status_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->status = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_status_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_status_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->status);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_height_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_height_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->height = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_height_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_height_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->height);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_width_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_width_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->width = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_width_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_width_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->width);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_maxsize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_maxsize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->maxsize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_maxsize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_maxsize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->maxsize);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_numlayers_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_numlayers_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numlayers);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_symbolset_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    symbolSetObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_symbolset_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (symbolSetObj *)& ((arg1)->symbolset);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_symbolSetObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_fontset_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    fontSetObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_fontset_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (fontSetObj *)& ((arg1)->fontset);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_fontSetObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_labelcache_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    labelCacheObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_labelcache_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (labelCacheObj *)& ((arg1)->labelcache);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelCacheObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_transparent_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_transparent_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->transparent = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_transparent_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_transparent_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->transparent);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_interlace_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_interlace_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->interlace = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_interlace_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_interlace_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->interlace);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_imagequality_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_imagequality_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->imagequality = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_imagequality_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_imagequality_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->imagequality);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_extent_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    rectObj *arg2 = (rectObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_extent_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_rectObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->extent = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_extent_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    rectObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_extent_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (rectObj *)& ((arg1)->extent);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_rectObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_cellsize_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:mapObj_cellsize_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->cellsize = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_cellsize_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_cellsize_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->cellsize);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_saved_extent_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    rectObj *arg2 = (rectObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_saved_extent_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_rectObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->saved_extent = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_saved_extent_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    rectObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_saved_extent_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (rectObj *)& ((arg1)->saved_extent);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_rectObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_units_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_units_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->units = (enum MS_UNITS)arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_units_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_units_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->units);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_scale_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:mapObj_scale_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->scale = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_scale_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_scale_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->scale);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_resolution_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    double arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:mapObj_resolution_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->resolution = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_resolution_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_resolution_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (double) ((arg1)->resolution);
    
    resultobj = PyFloat_FromDouble(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_shapepath_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_shapepath_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->shapepath) free((char*)arg1->shapepath);
        if (arg2) {
            arg1->shapepath = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->shapepath,arg2);
        } else {
            arg1->shapepath = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_shapepath_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_shapepath_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->shapepath);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_mappath_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_mappath_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->mappath) free((char*)arg1->mappath);
        if (arg2) {
            arg1->mappath = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->mappath,arg2);
        } else {
            arg1->mappath = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_mappath_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_mappath_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->mappath);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_imagecolor_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    colorObj *arg2 = (colorObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_imagecolor_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_colorObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->imagecolor = *arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_imagecolor_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    colorObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_imagecolor_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (colorObj *)& ((arg1)->imagecolor);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_colorObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_numoutputformats_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_numoutputformats_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->numoutputformats);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_outputformatlist_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    outputFormatObj **result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_outputformatlist_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (outputFormatObj **) ((arg1)->outputformatlist);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_p_outputFormatObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_outputformat_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    outputFormatObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_outputformat_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (outputFormatObj *) ((arg1)->outputformat);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_outputFormatObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_imagetype_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_imagetype_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->imagetype);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_reference_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    referenceMapObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_reference_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (referenceMapObj *)& ((arg1)->reference);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_referenceMapObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_scalebar_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    scalebarObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_scalebar_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (scalebarObj *)& ((arg1)->scalebar);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_scalebarObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_legend_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    legendObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_legend_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (legendObj *)& ((arg1)->legend);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_legendObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_querymap_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    queryMapObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_querymap_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (queryMapObj *)& ((arg1)->querymap);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_queryMapObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_web_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    webObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_web_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (webObj *)& ((arg1)->web);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_webObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_layerorder_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int *arg2 = (int *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_layerorder_set",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_int,SWIG_POINTER_EXCEPTION | SWIG_POINTER_DISOWN )) == -1) SWIG_fail;
    if (arg1) (arg1)->layerorder = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_layerorder_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_layerorder_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int *) ((arg1)->layerorder);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_int, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_debug_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_debug_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if (arg1) (arg1)->debug = arg2;
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_debug_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_debug_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (int) ((arg1)->debug);
    
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_datapattern_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_datapattern_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->datapattern) free((char*)arg1->datapattern);
        if (arg2) {
            arg1->datapattern = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->datapattern,arg2);
        } else {
            arg1->datapattern = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_datapattern_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_datapattern_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->datapattern);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_templatepattern_set(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_templatepattern_set",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        if (arg1->templatepattern) free((char*)arg1->templatepattern);
        if (arg2) {
            arg1->templatepattern = (char *) malloc(strlen(arg2)+1);
            strcpy((char*)arg1->templatepattern,arg2);
        } else {
            arg1->templatepattern = 0;
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_templatepattern_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_templatepattern_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (char *) ((arg1)->templatepattern);
    
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_configoptions_get(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    hashTableObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_configoptions_get",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    result = (hashTableObj *)& ((arg1)->configoptions);
    
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_hashTableObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_mapObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    char *arg1 = (char *) "" ;
    mapObj *result;
    
    if(!PyArg_ParseTuple(args,(char *)"|z:new_mapObj",&arg1)) goto fail;
    {
        result = (mapObj *)new_mapObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_mapObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_delete_mapObj(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:delete_mapObj",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        delete_mapObj(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_clone(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    mapObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_clone",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (mapObj *)mapObj_clone(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_mapObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_insertLayer(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    layerObj *arg2 = (layerObj *) 0 ;
    int arg3 = (int) -1 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO|i:mapObj_insertLayer",&obj0,&obj1,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_layerObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_insertLayer(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_removeLayer(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    layerObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_removeLayer",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (layerObj *)mapObj_removeLayer(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_layerObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setExtent(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    double arg2 ;
    double arg3 ;
    double arg4 ;
    double arg5 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Odddd:mapObj_setExtent",&obj0,&arg2,&arg3,&arg4,&arg5)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_setExtent(arg1,arg2,arg3,arg4,arg5);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setSize(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    int arg3 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oii:mapObj_setSize",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_setSize(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setRotation(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    double arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Od:mapObj_setRotation",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_setRotation(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getLayer(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    layerObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_getLayer",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (layerObj *)mapObj_getLayer(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_layerObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getLayerByName(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    layerObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_getLayerByName",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (layerObj *)mapObj_getLayerByName(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_layerObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getSymbolByName(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_getSymbolByName",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_getSymbolByName(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_prepareQuery(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_prepareQuery",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        mapObj_prepareQuery(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_prepareImage(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_prepareImage",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (imageObj *)mapObj_prepareImage(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_imageObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setImageType(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_setImageType",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        mapObj_setImageType(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_selectOutputFormat(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_selectOutputFormat",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        mapObj_selectOutputFormat(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setOutputFormat(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    outputFormatObj *arg2 = (outputFormatObj *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_setOutputFormat",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_outputFormatObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        mapObj_setOutputFormat(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_draw(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_draw",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (imageObj *)mapObj_draw(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_imageObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_drawQuery(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_drawQuery",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (imageObj *)mapObj_drawQuery(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_imageObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_drawLegend(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_drawLegend",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (imageObj *)mapObj_drawLegend(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_imageObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_drawScalebar(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_drawScalebar",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (imageObj *)mapObj_drawScalebar(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_imageObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_drawReferenceMap(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_drawReferenceMap",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (imageObj *)mapObj_drawReferenceMap(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_imageObj, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_embedScalebar(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *arg2 = (imageObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_embedScalebar",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_imageObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_embedScalebar(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_embedLegend(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *arg2 = (imageObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_embedLegend",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_imageObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_embedLegend(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_drawLabelCache(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    imageObj *arg2 = (imageObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_drawLabelCache",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_imageObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_drawLabelCache(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getLabel(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    labelCacheMemberObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_getLabel",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (labelCacheMemberObj *)mapObj_getLabel(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelCacheMemberObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_nextLabel(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    labelCacheMemberObj *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_nextLabel",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (labelCacheMemberObj *)mapObj_nextLabel(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = SWIG_NewPointerObj((void *) result, SWIGTYPE_p_labelCacheMemberObj, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_queryByPoint(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    pointObj *arg2 = (pointObj *) 0 ;
    int arg3 ;
    double arg4 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOid:mapObj_queryByPoint",&obj0,&obj1,&arg3,&arg4)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_pointObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_queryByPoint(arg1,arg2,arg3,arg4);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_queryByRect(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    rectObj arg2 ;
    int result;
    rectObj *argp2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_queryByRect",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &argp2, SWIGTYPE_p_rectObj,SWIG_POINTER_EXCEPTION) == -1)) SWIG_fail;
    arg2 = *argp2; 
    {
        result = (int)mapObj_queryByRect(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_queryByFeatures(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oi:mapObj_queryByFeatures",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_queryByFeatures(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_queryByShape(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    shapeObj *arg2 = (shapeObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:mapObj_queryByShape",&obj0,&obj1)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    if ((SWIG_ConvertPtr(obj1,(void **) &arg2, SWIGTYPE_p_shapeObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_queryByShape(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setWKTProjection(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_setWKTProjection",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_setWKTProjection(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getProjection(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_getProjection",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)mapObj_getProjection(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    free(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setProjection(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_setProjection",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_setProjection(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_save(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_save",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_save(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_saveQuery(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_saveQuery",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_saveQuery(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_loadQuery(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_loadQuery",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_loadQuery(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_freeQuery(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int arg2 = (int) -1 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O|i:mapObj_freeQuery",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        mapObj_freeQuery(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_saveQueryAsGML(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    char *arg3 = (char *) "GOMF" ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz|z:mapObj_saveQueryAsGML",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_saveQueryAsGML(arg1,arg2,(char const *)arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getMetaData(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_getMetaData",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)mapObj_getMetaData(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setMetaData(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    char *arg3 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Ozz:mapObj_setMetaData",&obj0,&arg2,&arg3)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_setMetaData(arg1,arg2,arg3);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_removeMetaData(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_removeMetaData",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_removeMetaData(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getFirstMetaDataKey(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_getFirstMetaDataKey",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)mapObj_getFirstMetaDataKey(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getNextMetaDataKey(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_getNextMetaDataKey",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (char *)mapObj_getNextMetaDataKey(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = result ? PyString_FromString(result) : Py_BuildValue((char*)"");
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setSymbolSet(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_setSymbolSet",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_setSymbolSet(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_getNumSymbols(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:mapObj_getNumSymbols",&obj0)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_getNumSymbols(arg1);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                case MS_IOERR:
                if (strcmp(ms_error->routine, "msSearchDiskTree()") != 0) {
                    _raise_ms_exception();
                    msResetErrorList();
                    return NULL;
                }
                default:
                _raise_ms_exception();
                msResetErrorList();
                return NULL;
            }
            
        }
    }
    resultobj = PyInt_FromLong((long)result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_mapObj_setFontSet(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    mapObj *arg1 = (mapObj *) 0 ;
    char *arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"Oz:mapObj_setFontSet",&obj0,&arg2)) goto fail;
    if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_mapObj,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail;
    {
        result = (int)mapObj_setFontSet(arg1,arg2);
        {
            errorObj *ms_error = msGetErrorObj();
            
            switch(ms_error->code) {
                case MS_NOERR:
                break;
                case MS_NOTFOUND:
                msResetErrorList();
                break;
                case -1:
                break;
                cas