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


#ifndef SWIGPYTHON
#define SWIGPYTHON
#endif

#define SWIG_PYTHON_THREADS
#define SWIG_PYTHON_DIRECTOR_NO_VTABLE

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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


#if defined(_DEBUG) && defined(SWIG_PYTHON_INTERPRETER_NO_DEBUG)
/* Use debug wrappers with the Python release dll */
# undef _DEBUG
# include <Python.h>
# define _DEBUG
#else
# include <Python.h>
#endif

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

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

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

/*
  You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
  creating a static or dynamic library from the SWIG runtime code.
  In 99.9% of the cases, SWIG just needs to declare them as 'static'.

  But only do this if strictly necessary, ie, if you have problems
  with your compiler or suchlike.
*/

#ifndef SWIGRUNTIME
# define SWIGRUNTIME SWIGINTERN
#endif

#ifndef SWIGRUNTIMEINLINE
# define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
#endif

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

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

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


/*
   Flags/methods for returning states.

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

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

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

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

   Now you can be more explicit:

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

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

    Type *ptr;
    int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
    if (SWIG_IsOK(res)) {
      // success code
      if (SWIG_IsNewObj(res) {
        ...
	delete *ptr;
      } else {
        ...
      }
    } else {
      // fail code
    }

   I.e., now SWIG_ConvertPtr can return new objects and you can
   identify the case and take care of the deallocation. Of course that
   also requires SWIG_ConvertPtr to return new result values, such as

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

   Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
   more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
   SWIG errors code.

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

       int food(double)
       int fooi(int);

   and you call

      food(1)   // cast rank '1'  (1 -> 1.0)
      fooi(1)   // cast rank '0'

   just use the SWIG_AddCast()/SWIG_CheckState()
*/

#define SWIG_OK                    (0)
#define SWIG_ERROR                 (-1)
#define SWIG_IsOK(r)               (r >= 0)
#define SWIG_ArgError(r)           ((r != SWIG_ERROR) ? r : SWIG_TypeError)

/* The CastRankLimit says how many bits are used for the cast rank */
#define SWIG_CASTRANKLIMIT         (1 << 8)
/* The NewMask denotes the object was created (using new/malloc) */
#define SWIG_NEWOBJMASK            (SWIG_CASTRANKLIMIT  << 1)
/* The TmpMask is for in/out typemaps that use temporal objects */
#define SWIG_TMPOBJMASK            (SWIG_NEWOBJMASK << 1)
/* Simple returning values */
#define SWIG_BADOBJ                (SWIG_ERROR)
#define SWIG_OLDOBJ                (SWIG_OK)
#define SWIG_NEWOBJ                (SWIG_OK | SWIG_NEWOBJMASK)
#define SWIG_TMPOBJ                (SWIG_OK | SWIG_TMPOBJMASK)
/* Check, add and del mask methods */
#define SWIG_AddNewMask(r)         (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r)
#define SWIG_DelNewMask(r)         (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r)
#define SWIG_IsNewObj(r)           (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK))
#define SWIG_AddTmpMask(r)         (SWIG_IsOK(r) ? (r | SWIG_TMPOBJMASK) : r)
#define SWIG_DelTmpMask(r)         (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
#define SWIG_IsTmpObj(r)           (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))

/* Cast-Rank Mode */
#if defined(SWIG_CASTRANK_MODE)
#  ifndef SWIG_TypeRank
#    define SWIG_TypeRank             unsigned long
#  endif
#  ifndef SWIG_MAXCASTRANK            /* Default cast allowed */
#    define SWIG_MAXCASTRANK          (2)
#  endif
#  define SWIG_CASTRANKMASK          ((SWIG_CASTRANKLIMIT) -1)
#  define SWIG_CastRank(r)           (r & SWIG_CASTRANKMASK)
SWIGINTERNINLINE int SWIG_AddCast(int r) {
  return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
}
SWIGINTERNINLINE int SWIG_CheckState(int r) {
  return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
}
#else /* no cast-rank mode */
#  define SWIG_AddCast(r) (r)
#  define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
#endif


#include <string.h>

#ifdef __cplusplus
extern "C" {
#endif

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

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

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

/* Structure used to store module information
 * Each module generates one structure like this, and the runtime collects
 * all of these structures and stores them in a circularly linked list.*/
typedef struct swig_module_info {
  swig_type_info         **types;		/* Array of pointers to swig_type_info structures that are in this module */
  size_t                 size;		        /* Number of types in this module */
  struct swig_module_info *next;		/* Pointer to next element in circularly linked list */
  swig_type_info         **type_initial;	/* Array of initially generated type structures */
  swig_cast_info         **cast_initial;	/* Array of initially generated casting structures */
  void                    *clientdata;		/* Language specific module data */
} swig_module_info;

/*
  Compare two type names skipping the space characters, therefore
  "char*" == "char *" and "Class<int>" == "Class<int >", etc.

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

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

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

/*
  Check the typename
*/
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheck(const char *c, swig_type_info *ty) {
  if (ty) {
    swig_cast_info *iter = ty->cast;
    while (iter) {
      if (strcmp(iter->type->name, c) == 0) {
        if (iter == ty->cast)
          return iter;
        /* Move iter to the top of the linked list */
        iter->prev->next = iter->next;
        if (iter->next)
          iter->next->prev = iter->prev;
        iter->next = ty->cast;
        iter->prev = 0;
        if (ty->cast) ty->cast->prev = iter;
        ty->cast = iter;
        return iter;
      }
      iter = iter->next;
    }
  }
  return 0;
}

/*
  Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
*/
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty) {
  if (ty) {
    swig_cast_info *iter = ty->cast;
    while (iter) {
      if (iter->type == from) {
        if (iter == ty->cast)
          return iter;
        /* Move iter to the top of the linked list */
        iter->prev->next = iter->next;
        if (iter->next)
          iter->next->prev = iter->prev;
        iter->next = ty->cast;
        iter->prev = 0;
        if (ty->cast) ty->cast->prev = iter;
        ty->cast = iter;
        return iter;
      }
      iter = iter->next;
    }
  }
  return 0;
}

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

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

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

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

/*
   Set the clientdata field for a type
*/
SWIGRUNTIME void
SWIG_TypeClientData(swig_type_info *ti, void *clientdata) {
  swig_cast_info *cast = ti->cast;
  /* if (ti->clientdata == clientdata) return; */
  ti->clientdata = clientdata;

  while (cast) {
    if (!cast->converter) {
      swig_type_info *tc = cast->type;
      if (!tc->clientdata) {
	SWIG_TypeClientData(tc, clientdata);
      }
    }
    cast = cast->next;
  }
}
SWIGRUNTIME void
SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata) {
  SWIG_TypeClientData(ti, clientdata);
  ti->owndata = 1;
}

/*
  Search for a swig_type_info structure only by mangled name
  Search is a O(log #types)

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

/*
  Search for a swig_type_info structure for either a mangled name or a human readable name.
  It first searches the mangled names of the types, which is a O(log #types)
  If a type is not found it then searches the human readable names, which is O(#types).

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

  /* neither found a match */
  return 0;
}

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

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

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

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

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

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

#ifdef __cplusplus
}
#endif

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



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

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

#endif

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

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

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


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

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


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

/* Add PyOS_snprintf for old Pythons */
#if PY_VERSION_HEX < 0x02020000
# if defined(_MSC_VER) || defined(__BORLANDC__) || defined(_WATCOM)
#  define PyOS_snprintf _snprintf
# else
#  define PyOS_snprintf snprintf
# endif
#endif

/* A crude PyString_FromFormat implementation for old Pythons */
#if PY_VERSION_HEX < 0x02020000

#ifndef SWIG_PYBUFFER_SIZE
# define SWIG_PYBUFFER_SIZE 1024
#endif

static PyObject *
PyString_FromFormat(const char *fmt, ...) {
  va_list ap;
  char buf[SWIG_PYBUFFER_SIZE * 2];
  int res;
  va_start(ap, fmt);
  res = vsnprintf(buf, sizeof(buf), fmt, ap);
  va_end(ap);
  return (res < 0 || res >= (int)sizeof(buf)) ? 0 : PyString_FromString(buf);
}
#endif

#ifndef PyObject_DEL
# define PyObject_DEL PyObject_Del
#endif

/* A crude PyExc_StopIteration exception for old Pythons */
#if PY_VERSION_HEX < 0x02020000
# ifndef PyExc_StopIteration
#  define PyExc_StopIteration PyExc_RuntimeError
# endif
# ifndef PyObject_GenericGetAttr
#  define PyObject_GenericGetAttr 0
# endif
#endif

/* Py_NotImplemented is defined in 2.1 and up. */
#if PY_VERSION_HEX < 0x02010000
# ifndef Py_NotImplemented
#  define Py_NotImplemented PyExc_RuntimeError
# endif
#endif

/* A crude PyString_AsStringAndSize implementation for old Pythons */
#if PY_VERSION_HEX < 0x02010000
# ifndef PyString_AsStringAndSize
#  define PyString_AsStringAndSize(obj, s, len) {*s = PyString_AsString(obj); *len = *s ? strlen(*s) : 0;}
# endif
#endif

/* PySequence_Size for old Pythons */
#if PY_VERSION_HEX < 0x02000000
# ifndef PySequence_Size
#  define PySequence_Size PySequence_Length
# endif
#endif

/* PyBool_FromLong for old Pythons */
#if PY_VERSION_HEX < 0x02030000
static
PyObject *PyBool_FromLong(long ok)
{
  PyObject *result = ok ? Py_True : Py_False;
  Py_INCREF(result);
  return result;
}
#endif

/* Py_ssize_t for old Pythons */
/* This code is as recommended by: */
/* http://www.python.org/dev/peps/pep-0353/#conversion-guidelines */
#if PY_VERSION_HEX < 0x02050000 && !defined(PY_SSIZE_T_MIN)
typedef int Py_ssize_t;
# define PY_SSIZE_T_MAX INT_MAX
# define PY_SSIZE_T_MIN INT_MIN
typedef inquiry lenfunc;
typedef intargfunc ssizeargfunc;
typedef intintargfunc ssizessizeargfunc;
typedef intobjargproc ssizeobjargproc;
typedef intintobjargproc ssizessizeobjargproc;
typedef getreadbufferproc readbufferproc;
typedef getwritebufferproc writebufferproc;
typedef getsegcountproc segcountproc;
typedef getcharbufferproc charbufferproc;
static long PyNumber_AsSsize_t (PyObject *x, void *SWIGUNUSEDPARM(exc))
{
  long result = 0;
  PyObject *i = PyNumber_Int(x);
  if (i) {
    result = PyInt_AsLong(i);
    Py_DECREF(i);
  }
  return result;
}
#endif

#if PY_VERSION_HEX < 0x02050000
#define PyInt_FromSize_t(x) PyInt_FromLong((long)x)
#endif

#if PY_VERSION_HEX < 0x02040000
#define Py_VISIT(op)				\
  do { 						\
    if (op) {					\
      int vret = visit((op), arg);		\
      if (vret)					\
        return vret;				\
    }						\
  } while (0)
#endif

#if PY_VERSION_HEX < 0x02030000
typedef struct {
  PyTypeObject type;
  PyNumberMethods as_number;
  PyMappingMethods as_mapping;
  PySequenceMethods as_sequence;
  PyBufferProcs as_buffer;
  PyObject *name, *slots;
} PyHeapTypeObject;
#endif

#if PY_VERSION_HEX < 0x02030000
typedef destructor freefunc;
#endif

#if ((PY_MAJOR_VERSION == 2 && PY_MINOR_VERSION > 6) || \
     (PY_MAJOR_VERSION == 3 && PY_MINOR_VERSION > 0) || \
     (PY_MAJOR_VERSION > 3))
# define SWIGPY_USE_CAPSULE
# define SWIGPY_CAPSULE_NAME ((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION ".type_pointer_capsule" SWIG_TYPE_TABLE_NAME)
#endif

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

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

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


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

  if (PyErr_Occurred()) PyErr_Fetch(&type, &value, &traceback);
  if (value) {
    char *tmp;
    PyObject *old_str = PyObject_Str(value);
    PyErr_Clear();
    Py_XINCREF(type);

    PyErr_Format(type, "%s %s", tmp = SWIG_Python_str_AsChar(old_str), mesg);
    SWIG_Python_str_DelForPy3(tmp);
    Py_DECREF(old_str);
    Py_DECREF(value);
  } else {
    PyErr_SetString(PyExc_RuntimeError, mesg);
  }
}

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

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

#ifdef __cplusplus
extern "C" {
#endif

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

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

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


/* -----------------------------------------------------------------------------
 * Wrapper of PyInstanceMethod_New() used in Python 3
 * It is exported to the generated module, used for -fastproxy
 * ----------------------------------------------------------------------------- */
#if PY_VERSION_HEX >= 0x03000000
SWIGRUNTIME PyObject* SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func)
{
  return PyInstanceMethod_New(func);
}
#else
SWIGRUNTIME PyObject* SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *SWIGUNUSEDPARM(func))
{
  return NULL;
}
#endif

#ifdef __cplusplus
}
#endif


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

/* Common SWIG API */

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

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

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

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

/* for raw packed data */
#define SWIG_ConvertPacked(obj, ptr, sz, ty)            SWIG_Python_ConvertPacked(obj, ptr, sz, ty)
#define SWIG_NewPackedObj(ptr, sz, type)                SWIG_Python_NewPackedObj(ptr, sz, type)

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

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

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


/* Runtime API */

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

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


/* Runtime API implementation */

/* Error manipulation */

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

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

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

/* Set a constant value */

#if defined(SWIGPYTHON_BUILTIN)

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

SWIGINTERN void
SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *name, PyObject *obj) {   
#if PY_VERSION_HEX < 0x02030000
  PyDict_SetItemString(d, (char *)name, obj);
#else
  PyDict_SetItemString(d, name, obj);
#endif
  Py_DECREF(obj);
  if (public_interface)
    SwigPyBuiltin_AddPublicSymbol(public_interface, name);
}

#else

SWIGINTERN void
SWIG_Python_SetConstant(PyObject *d, const char *name, PyObject *obj) {   
#if PY_VERSION_HEX < 0x02030000
  PyDict_SetItemString(d, (char *)name, obj);
#else
  PyDict_SetItemString(d, name, obj);
#endif
  Py_DECREF(obj);                            
}

#endif

/* Append a value to the result obj */

SWIGINTERN PyObject*
SWIG_Python_AppendOutput(PyObject* result, PyObject* obj) {
#if !defined(SWIG_PYTHON_OUTPUT_TUPLE)
  if (!result) {
    result = obj;
  } else if (result == Py_None) {
    Py_DECREF(result);
    result = obj;
  } else {
    if (!PyList_Check(result)) {
      PyObject *o2 = result;
      result = PyList_New(1);
      PyList_SetItem(result, 0, o2);
    }
    PyList_Append(result,obj);
    Py_DECREF(obj);
  }
  return result;
#else
  PyObject*   o2;
  PyObject*   o3;
  if (!result) {
    result = obj;
  } else if (result == Py_None) {
    Py_DECREF(result);
    result = obj;
  } else {
    if (!PyTuple_Check(result)) {
      o2 = result;
      result = PyTuple_New(1);
      PyTuple_SET_ITEM(result, 0, o2);
    }
    o3 = PyTuple_New(1);
    PyTuple_SET_ITEM(o3, 0, obj);
    o2 = result;
    result = PySequence_Concat(o2, o3);
    Py_DECREF(o2);
    Py_DECREF(o3);
  }
  return result;
#endif
}

/* Unpack the argument tuple */

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

/* A functor is a function object with one single object argument */
#if PY_VERSION_HEX >= 0x02020000
#define SWIG_Python_CallFunctor(functor, obj)	        PyObject_CallFunctionObjArgs(functor, obj, NULL);
#else
#define SWIG_Python_CallFunctor(functor, obj)	        PyObject_CallFunction(functor, "O", obj);
#endif

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

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

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

#define SWIG_POINTER_IMPLICIT_CONV  (SWIG_POINTER_DISOWN   << 1)

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

#ifdef __cplusplus
extern "C" {
#endif

/*  How to access Py_None */
#if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
#  ifndef SWIG_PYTHON_NO_BUILD_NONE
#    ifndef SWIG_PYTHON_BUILD_NONE
#      define SWIG_PYTHON_BUILD_NONE
#    endif
#  endif
#endif

#ifdef SWIG_PYTHON_BUILD_NONE
#  ifdef Py_None
#   undef Py_None
#   define Py_None SWIG_Py_None()
#  endif
SWIGRUNTIMEINLINE PyObject * 
_SWIG_Py_None(void)
{
  PyObject *none = Py_BuildValue((char*)"");
  Py_DECREF(none);
  return none;
}
SWIGRUNTIME PyObject * 
SWIG_Py_None(void)
{
  static PyObject *SWIG_STATIC_POINTER(none) = _SWIG_Py_None();
  return none;
}
#endif

/* The python void return value */

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

/* SwigPyClientData */

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

SWIGRUNTIMEINLINE int 
SWIG_Python_CheckImplicit(swig_type_info *ty)
{
  SwigPyClientData *data = (SwigPyClientData *)ty->clientdata;
  return data ? data->implicitconv : 0;
}

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


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

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

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

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


#ifdef SWIGPYTHON_BUILTIN

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

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

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

#endif

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

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

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

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

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

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

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

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


SWIGRUNTIME PyTypeObject* SwigPyObject_TypeOnce(void);

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

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

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

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

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

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

      PyErr_Restore(val, type, tb);

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

SWIGRUNTIME PyObject* 
SwigPyObject_append(PyObject* v, PyObject* next)
{
  SwigPyObject *sobj = (SwigPyObject *) v;
#ifndef METH_O
  PyObject *tmp = 0;
  if (!PyArg_ParseTuple(next,(char *)"O:append", &tmp)) return NULL;
  next = tmp;
#endif
  if (!SwigPyObject_Check(next)) {
    PyErr_SetString(PyExc_TypeError, "Attempt to append a non SwigPyObject");
    return NULL;
  }
  sobj->next = next;
  Py_INCREF(next);
  return SWIG_Py_Void();
}

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

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

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

#ifdef METH_NOARGS
static PyObject*
SwigPyObject_disown2(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
{
  return SwigPyObject_disown(v);
}

static PyObject*
SwigPyObject_acquire2(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
{
  return SwigPyObject_acquire(v);
}
#endif

SWIGINTERN PyObject*
SwigPyObject_own(PyObject *v, PyObject *args)
{
  PyObject *val = 0;
#if (PY_VERSION_HEX < 0x02020000)
  if (!PyArg_ParseTuple(args,(char *)"|O:own",&val))
#elif (PY_VERSION_HEX < 0x02050000)
  if (!PyArg_UnpackTuple(args, (char *)"own", 0, 1, &val)) 
#else
  if (!PyArg_UnpackTuple(args, "own", 0, 1, &val)) 
#endif
    {
      return NULL;
    } 
  else
    {
      SwigPyObject *sobj = (SwigPyObject *)v;
      PyObject *obj = PyBool_FromLong(sobj->own);
      if (val) {
#ifdef METH_NOARGS
	if (PyObject_IsTrue(val)) {
	  SwigPyObject_acquire(v);
	} else {
	  SwigPyObject_disown(v);
	}
#else
	if (PyObject_IsTrue(val)) {
	  SwigPyObject_acquire(v,args);
	} else {
	  SwigPyObject_disown(v,args);
	}
#endif
      } 
      return obj;
    }
}

#ifdef METH_O
static PyMethodDef
swigobject_methods[] = {
  {(char *)"disown",  (PyCFunction)SwigPyObject_disown2, METH_NOARGS,  (char *)"releases ownership of the pointer"},
  {(char *)"acquire", (PyCFunction)SwigPyObject_acquire2,METH_NOARGS,  (char *)"acquires ownership of the pointer"},
  {(char *)"own",     (PyCFunction)SwigPyObject_own,     METH_VARARGS, (char *)"returns/sets ownership of the pointer"},
  {(char *)"append",  (PyCFunction)SwigPyObject_append,  METH_O,       (char *)"appends another 'this' object"},
  {(char *)"next",    (PyCFunction)SwigPyObject_next,    METH_NOARGS,  (char *)"returns the next 'this' object"},
  {(char *)"__repr__",(PyCFunction)SwigPyObject_repr2,   METH_NOARGS,  (char *)"returns object representation"},
  {0, 0, 0, 0}  
};
#else
static PyMethodDef
swigobject_methods[] = {
  {(char *)"disown",  (PyCFunction)SwigPyObject_disown,  METH_VARARGS,  (char *)"releases ownership of the pointer"},
  {(char *)"acquire", (PyCFunction)SwigPyObject_acquire, METH_VARARGS,  (char *)"acquires ownership of the pointer"},
  {(char *)"own",     (PyCFunction)SwigPyObject_own,     METH_VARARGS,  (char *)"returns/sets ownership of the pointer"},
  {(char *)"append",  (PyCFunction)SwigPyObject_append,  METH_VARARGS,  (char *)"appends another 'this' object"},
  {(char *)"next",    (PyCFunction)SwigPyObject_next,    METH_VARARGS,  (char *)"returns the next 'this' object"},
  {(char *)"__repr__",(PyCFunction)SwigPyObject_repr,    METH_VARARGS,  (char *)"returns object representation"},
  {0, 0, 0, 0}  
};
#endif

#if PY_VERSION_HEX < 0x02020000
SWIGINTERN PyObject *
SwigPyObject_getattr(SwigPyObject *sobj,char *name)
{
  return Py_FindMethod(swigobject_methods, (PyObject *)sobj, name);
}
#endif

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

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

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

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

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

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

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

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

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

SWIGRUNTIME PyTypeObject* SwigPyPacked_TypeOnce(void);

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

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

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

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

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

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

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

SWIGRUNTIMEINLINE PyObject *
_SWIG_This(void)
{
    return SWIG_Python_str_FromChar("this");
}

static PyObject *swig_this = NULL;

SWIGRUNTIME PyObject *
SWIG_This(void)
{
  if (swig_this == NULL)
    swig_this = _SWIG_This();
  return swig_this;
}

/* #define SWIG_PYTHON_SLOW_GETSET_THIS */

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

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

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

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

  obj = 0;

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

/* Acquire a pointer value */

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

/* Convert a pointer value */

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

  if (!obj)
    return SWIG_ERROR;
  if (obj == Py_None && !implicit_conv) {
    if (ptr)
      *ptr = 0;
    return SWIG_OK;
  }

  res = SWIG_ERROR;

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

/* Convert a function ptr value */

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

/* Convert a packed value value */

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

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

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

SWIGRUNTIME PyObject* 
SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
{
#if (PY_VERSION_HEX >= 0x02020000)
  PyObject *inst = 0;
  PyObject *newraw = data->newraw;
  if (newraw) {
    inst = PyObject_Call(newraw, data->newargs, NULL);
    if (inst) {
#if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
      PyObject **dictptr = _PyObject_GetDictPtr(inst);
      if (dictptr != NULL) {
	PyObject *dict = *dictptr;
	if (dict == NULL) {
	  dict = PyDict_New();
	  *dictptr = dict;
	  PyDict_SetItem(dict, SWIG_This(), swig_this);
	}
      }
#else
      PyObject *key = SWIG_This();
      PyObject_SetAttr(inst, key, swig_this);
#endif
    }
  } else {
#if PY_VERSION_HEX >= 0x03000000
    inst = ((PyTypeObject*) data->newargs)->tp_new((PyTypeObject*) data->newargs, Py_None, Py_None);
    if (inst) {
      PyObject_SetAttr(inst, SWIG_This(), swig_this);
      Py_TYPE(inst)->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG;
    }
#else
    PyObject *dict = PyDict_New();
    if (dict) {
      PyDict_SetItem(dict, SWIG_This(), swig_this);
      inst = PyInstance_NewRaw(data->newargs, dict);
      Py_DECREF(dict);
    }
#endif
  }
  return inst;
#else
#if (PY_VERSION_HEX >= 0x02010000)
  PyObject *inst = 0;
  PyObject *dict = PyDict_New();
  if (dict) {
    PyDict_SetItem(dict, SWIG_This(), swig_this);
    inst = PyInstance_NewRaw(data->newargs, dict);
    Py_DECREF(dict);
  }
  return (PyObject *) inst;
#else
  PyInstanceObject *inst = PyObject_NEW(PyInstanceObject, &PyInstance_Type);
  if (inst == NULL) {
    return NULL;
  }
  inst->in_class = (PyClassObject *)data->newargs;
  Py_INCREF(inst->in_class);
  inst->in_dict = PyDict_New();
  if (inst->in_dict == NULL) {
    Py_DECREF(inst);
    return NULL;
  }
#ifdef Py_TPFLAGS_HAVE_WEAKREFS
  inst->in_weakreflist = NULL;
#endif
#ifdef Py_TPFLAGS_GC
  PyObject_GC_Init(inst);
#endif
  PyDict_SetItem(inst->in_dict, SWIG_This(), swig_this);
  return (PyObject *) inst;
#endif
#endif
}

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


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

/* Create a new pointer object */

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

  if (!ptr)
    return SWIG_Py_Void();

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

  assert(!(flags & SWIG_BUILTIN_TP_INIT));

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

/* Create a new packed object */

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

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

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

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

#if PY_MAJOR_VERSION < 2
/* PyModule_AddObject function was introduced in Python 2.0.  The following function
   is copied out of Python/modsupport.c in python version 2.3.4 */
SWIGINTERN int
PyModule_AddObject(PyObject *m, char *name, PyObject *o)
{
  PyObject *dict;
  if (!PyModule_Check(m)) {
    PyErr_SetString(PyExc_TypeError, "PyModule_AddObject() needs module as first arg");
    return SWIG_ERROR;
  }
  if (!o) {
    PyErr_SetString(PyExc_TypeError, "PyModule_AddObject() needs non-NULL value");
    return SWIG_ERROR;
  }
  
  dict = PyModule_GetDict(m);
  if (dict == NULL) {
    /* Internal error -- modules must have a dict! */
    PyErr_Format(PyExc_SystemError, "module '%s' has no __dict__",
		 PyModule_GetName(m));
    return SWIG_ERROR;
  }
  if (PyDict_SetItemString(dict, name, o))
    return SWIG_ERROR;
  Py_DECREF(o);
  return SWIG_OK;
}
#endif

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

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

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

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

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

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

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

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


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

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

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

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

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


#ifdef __cplusplus
}
#endif



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

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



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

#define SWIGTYPE_p_FILE swig_types[0]
#define SWIGTYPE_p__gpgme_attr_t swig_types[1]
#define SWIGTYPE_p__gpgme_engine_info swig_types[2]
#define SWIGTYPE_p__gpgme_import_status swig_types[3]
#define SWIGTYPE_p__gpgme_invalid_key swig_types[4]
#define SWIGTYPE_p__gpgme_key swig_types[5]
#define SWIGTYPE_p__gpgme_key_sig swig_types[6]
#define SWIGTYPE_p__gpgme_new_signature swig_types[7]
#define SWIGTYPE_p__gpgme_op_assuan_result swig_types[8]
#define SWIGTYPE_p__gpgme_op_decrypt_result swig_types[9]
#define SWIGTYPE_p__gpgme_op_encrypt_result swig_types[10]
#define SWIGTYPE_p__gpgme_op_genkey_result swig_types[11]
#define SWIGTYPE_p__gpgme_op_import_result swig_types[12]
#define SWIGTYPE_p__gpgme_op_keylist_result swig_types[13]
#define SWIGTYPE_p__gpgme_op_query_swdb_result swig_types[14]
#define SWIGTYPE_p__gpgme_op_sign_result swig_types[15]
#define SWIGTYPE_p__gpgme_op_verify_result swig_types[16]
#define SWIGTYPE_p__gpgme_op_vfs_mount_result swig_types[17]
#define SWIGTYPE_p__gpgme_recipient swig_types[18]
#define SWIGTYPE_p__gpgme_sig_notation swig_types[19]
#define SWIGTYPE_p__gpgme_sig_stat_t swig_types[20]
#define SWIGTYPE_p__gpgme_signature swig_types[21]
#define SWIGTYPE_p__gpgme_subkey swig_types[22]
#define SWIGTYPE_p__gpgme_tofu_info swig_types[23]
#define SWIGTYPE_p__gpgme_trust_item swig_types[24]
#define SWIGTYPE_p__gpgme_user_id swig_types[25]
#define SWIGTYPE_p_a___p__gpgme_key swig_types[26]
#define SWIGTYPE_p_char swig_types[27]
#define SWIGTYPE_p_f_p_void__void swig_types[28]
#define SWIGTYPE_p_f_p_void_enum_gpgme_event_io_t_p_void__void swig_types[29]
#define SWIGTYPE_p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t swig_types[30]
#define SWIGTYPE_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t swig_types[31]
#define SWIGTYPE_p_f_p_void_off_t_int__off_t swig_types[32]
#define SWIGTYPE_p_f_p_void_p_char_size_t_p_size_t__int swig_types[33]
#define SWIGTYPE_p_f_p_void_p_q_const__char_int_int_int__void swig_types[34]
#define SWIGTYPE_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t swig_types[35]
#define SWIGTYPE_p_f_p_void_p_q_const__char_p_q_const__char_int__gpg_error_t swig_types[36]
#define SWIGTYPE_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t swig_types[37]
#define SWIGTYPE_p_f_p_void_p_q_const__char_p_q_const__char_p_p_struct_gpgme_data__gpg_error_t swig_types[38]
#define SWIGTYPE_p_f_p_void_p_q_const__void_size_t__gpg_error_t swig_types[39]
#define SWIGTYPE_p_f_p_void_p_q_const__void_size_t__ssize_t swig_types[40]
#define SWIGTYPE_p_f_p_void_p_void_size_t__ssize_t swig_types[41]
#define SWIGTYPE_p_gpg_err_code_t swig_types[42]
#define SWIGTYPE_p_gpg_err_source_t swig_types[43]
#define SWIGTYPE_p_gpg_error_t swig_types[44]
#define SWIGTYPE_p_gpgme_conf_arg swig_types[45]
#define SWIGTYPE_p_gpgme_conf_arg_value swig_types[46]
#define SWIGTYPE_p_gpgme_conf_comp swig_types[47]
#define SWIGTYPE_p_gpgme_conf_level_t swig_types[48]
#define SWIGTYPE_p_gpgme_conf_opt swig_types[49]
#define SWIGTYPE_p_gpgme_conf_type_t swig_types[50]
#define SWIGTYPE_p_gpgme_context swig_types[51]
#define SWIGTYPE_p_gpgme_data swig_types[52]
#define SWIGTYPE_p_gpgme_data_cbs swig_types[53]
#define SWIGTYPE_p_gpgme_data_encoding_t swig_types[54]
#define SWIGTYPE_p_gpgme_data_type_t swig_types[55]
#define SWIGTYPE_p_gpgme_decrypt_flags_t swig_types[56]
#define SWIGTYPE_p_gpgme_encrypt_flags_t swig_types[57]
#define SWIGTYPE_p_gpgme_event_io_t swig_types[58]
#define SWIGTYPE_p_gpgme_hash_algo_t swig_types[59]
#define SWIGTYPE_p_gpgme_io_cbs swig_types[60]
#define SWIGTYPE_p_gpgme_io_event_done_data swig_types[61]
#define SWIGTYPE_p_gpgme_keyorg_t swig_types[62]
#define SWIGTYPE_p_gpgme_pinentry_mode_t swig_types[63]
#define SWIGTYPE_p_gpgme_protocol_t swig_types[64]
#define SWIGTYPE_p_gpgme_pubkey_algo_t swig_types[65]
#define SWIGTYPE_p_gpgme_sig_mode_t swig_types[66]
#define SWIGTYPE_p_gpgme_sigsum_t swig_types[67]
#define SWIGTYPE_p_gpgme_status_code_t swig_types[68]
#define SWIGTYPE_p_gpgme_tofu_policy_t swig_types[69]
#define SWIGTYPE_p_gpgme_validity_t swig_types[70]
#define SWIGTYPE_p_gpgrt_stream_t swig_types[71]
#define SWIGTYPE_p_int swig_types[72]
#define SWIGTYPE_p_off_t swig_types[73]
#define SWIGTYPE_p_p__gpgme_engine_info swig_types[74]
#define SWIGTYPE_p_p__gpgme_import_status swig_types[75]
#define SWIGTYPE_p_p__gpgme_key swig_types[76]
#define SWIGTYPE_p_p__gpgme_key_sig swig_types[77]
#define SWIGTYPE_p_p__gpgme_op_encrypt_result swig_types[78]
#define SWIGTYPE_p_p__gpgme_op_genkey_result swig_types[79]
#define SWIGTYPE_p_p__gpgme_op_import_result swig_types[80]
#define SWIGTYPE_p_p__gpgme_op_verify_result swig_types[81]
#define SWIGTYPE_p_p__gpgme_sig_notation swig_types[82]
#define SWIGTYPE_p_p__gpgme_signature swig_types[83]
#define SWIGTYPE_p_p__gpgme_subkey swig_types[84]
#define SWIGTYPE_p_p__gpgme_trust_item swig_types[85]
#define SWIGTYPE_p_p__gpgme_user_id swig_types[86]
#define SWIGTYPE_p_p_char swig_types[87]
#define SWIGTYPE_p_p_f_p_void__void swig_types[88]
#define SWIGTYPE_p_p_f_p_void_enum_gpgme_event_io_t_p_void__void swig_types[89]
#define SWIGTYPE_p_p_f_p_void_int__gpg_error_t swig_types[90]
#define SWIGTYPE_p_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t swig_types[91]
#define SWIGTYPE_p_p_f_p_void_off_t_int__off_t swig_types[92]
#define SWIGTYPE_p_p_f_p_void_p_q_const__char_int_int_int__void swig_types[93]
#define SWIGTYPE_p_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t swig_types[94]
#define SWIGTYPE_p_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t swig_types[95]
#define SWIGTYPE_p_p_f_p_void_p_q_const__void_size_t__ssize_t swig_types[96]
#define SWIGTYPE_p_p_f_p_void_p_void_size_t__ssize_t swig_types[97]
#define SWIGTYPE_p_p_gpgme_conf_arg swig_types[98]
#define SWIGTYPE_p_p_gpgme_conf_comp swig_types[99]
#define SWIGTYPE_p_p_gpgme_conf_opt swig_types[100]
#define SWIGTYPE_p_p_gpgme_context swig_types[101]
#define SWIGTYPE_p_p_gpgme_data swig_types[102]
#define SWIGTYPE_p_p_void swig_types[103]
#define SWIGTYPE_p_size_t swig_types[104]
#define SWIGTYPE_p_ssize_t swig_types[105]
#define SWIGTYPE_p_time_t swig_types[106]
#define SWIGTYPE_p_unsigned_int swig_types[107]
#define SWIGTYPE_p_void swig_types[108]
static swig_type_info *swig_types[110];
static swig_module_info swig_module = {swig_types, 109, 0, 0, 0, 0};
#define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)

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

#if (PY_VERSION_HEX <= 0x02000000)
# if !defined(SWIG_PYTHON_CLASSIC)
#  error "This python version requires swig to be run with the '-classic' option"
# endif
#endif

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

#else
#  define SWIG_init    init_gpgme

#endif
#define SWIG_name    "_gpgme"

#define SWIGVERSION 0x030012 
#define SWIG_VERSION SWIGVERSION


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


/* We use public symbols (eg. "_obsolete_class") which are marked as
 * deprecated but we need to keep them.  Silence the warning.  */
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"


#include "data.h"	/* For struct gpgme_data.  */


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


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


#include <float.h>


#include <math.h>


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


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


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


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


SWIGINTERN int
SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
{
#if PY_VERSION_HEX>=0x03000000
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
  if (PyBytes_Check(obj))
#else
  if (PyUnicode_Check(obj))
#endif
#else  
  if (PyString_Check(obj))
#endif
  {
    char *cstr; Py_ssize_t len;
#if PY_VERSION_HEX>=0x03000000
#if !defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
    if (!alloc && cptr) {
        /* We can't allow converting without allocation, since the internal
           representation of string in Python 3 is UCS-2/UCS-4 but we require
           a UTF-8 representation.
           TODO(bhy) More detailed explanation */
        return SWIG_RuntimeError;
    }
    obj = PyUnicode_AsUTF8String(obj);
    if(alloc) *alloc = SWIG_NEWOBJ;
#endif
    PyBytes_AsStringAndSize(obj, &cstr, &len);
#else
    PyString_AsStringAndSize(obj, &cstr, &len);
#endif
    if (cptr) {
      if (alloc) {
	/* 
	   In python the user should not be able to modify the inner
	   string representation. To warranty that, if you define
	   SWIG_PYTHON_SAFE_CSTRINGS, a new/copy of the python string
	   buffer is always returned.

	   The default behavior is just to return the pointer value,
	   so, be careful.
	*/ 
#if defined(SWIG_PYTHON_SAFE_CSTRINGS)
	if (*alloc != SWIG_OLDOBJ) 
#else
	if (*alloc == SWIG_NEWOBJ) 
#endif
	{
	  *cptr = (char *)memcpy(malloc((len + 1)*sizeof(char)), cstr, sizeof(char)*(len + 1));
	  *alloc = SWIG_NEWOBJ;
	} else {
	  *cptr = cstr;
	  *alloc = SWIG_OLDOBJ;
	}
      } else {
#if PY_VERSION_HEX>=0x03000000
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
	*cptr = PyBytes_AsString(obj);
#else
	assert(0); /* Should never reach here with Unicode strings in Python 3 */
#endif
#else
	*cptr = SWIG_Python_str_AsChar(obj);
#endif
      }
    }
    if (psize) *psize = len + 1;
#if PY_VERSION_HEX>=0x03000000 && !defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
    Py_XDECREF(obj);
#endif
    return SWIG_OK;
  } else {
#if defined(SWIG_PYTHON_2_UNICODE)
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
#error "Cannot use both SWIG_PYTHON_2_UNICODE and SWIG_PYTHON_STRICT_BYTE_CHAR at once"
#endif
#if PY_VERSION_HEX<0x03000000
    if (PyUnicode_Check(obj)) {
      char *cstr; Py_ssize_t len;
      if (!alloc && cptr) {
        return SWIG_RuntimeError;
      }
      obj = PyUnicode_AsUTF8String(obj);
      if (PyString_AsStringAndSize(obj, &cstr, &len) != -1) {
        if (cptr) {
          if (alloc) *alloc = SWIG_NEWOBJ;
          *cptr = (char *)memcpy(malloc((len + 1)*sizeof(char)), cstr, sizeof(char)*(len + 1));
        }
        if (psize) *psize = len + 1;

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

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





#ifdef HAVE_CONFIG_H
#include "config.h"
#endif

#include <gpgme.h>


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


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


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


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


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


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


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


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


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


SWIGINTERNINLINE int
SWIG_AsVal_size_t (PyObject * obj, size_t *val)
{
  int res = SWIG_TypeError;
#ifdef SWIG_LONG_LONG_AVAILABLE
  if (sizeof(size_t) <= sizeof(unsigned long)) {
#endif
    unsigned long v;
    res = SWIG_AsVal_unsigned_SS_long (obj, val ? &v : 0);
    if (SWIG_IsOK(res) && val) *val = (size_t)(v);
#ifdef SWIG_LONG_LONG_AVAILABLE
  } else if (sizeof(size_t) <= sizeof(unsigned long long)) {
    unsigned long long v;
    res = SWIG_AsVal_unsigned_SS_long_SS_long (obj, val ? &v : 0);
    if (SWIG_IsOK(res) && val) *val = (size_t)(v);
  }
#endif
  return res;
}


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


  #define SWIG_From_long   PyInt_FromLong 


SWIGINTERNINLINE PyObject* 
SWIG_From_unsigned_SS_long  (unsigned long value)
{
  return (value > LONG_MAX) ?
    PyLong_FromUnsignedLong(value) : PyInt_FromLong((long)(value));
}


SWIGINTERNINLINE PyObject *
SWIG_From_unsigned_SS_short  (unsigned short value)
{    
  return SWIG_From_unsigned_SS_long  (value);
}


SWIGINTERN int
SWIG_AsCharArray(PyObject * obj, char *val, size_t size)
{ 
  char* cptr = 0; size_t csize = 0; int alloc = SWIG_OLDOBJ;
  int res = SWIG_AsCharPtrAndSize(obj, &cptr, &csize, &alloc);
  if (SWIG_IsOK(res)) {
    /* special case of single char conversion when we don't need space for NUL */
    if (size == 1 && csize == 2 && cptr && !cptr[1]) --csize;
    if (csize <= size) {
      if (val) {
	if (csize) memcpy(val, cptr, csize*sizeof(char));
	if (csize < size) memset(val + csize, 0, (size - csize)*sizeof(char));
      }
      if (alloc == SWIG_NEWOBJ) {
	free((char*)cptr);
	res = SWIG_DelNewMask(res);
      }      
      return res;
    }
    if (alloc == SWIG_NEWOBJ) free((char*)cptr);
  }
  return SWIG_TypeError;
}


SWIGINTERN size_t
SWIG_strnlen(const char* s, size_t maxlen)
{
  const char *p;
  for (p = s; maxlen-- && *p; p++)
    ;
  return p - s;
}

typedef union {
  unsigned int count;
  unsigned int uint32;
  int int32;
  char *string;
} gpgme_conf_arg_value;


  static gpgme_ctx_t *new_gpgme_ctx_t_p() { 
    return (gpgme_ctx_t *)calloc(1,sizeof(gpgme_ctx_t));
  }
  
  static gpgme_ctx_t *copy_gpgme_ctx_t_p(gpgme_ctx_t value) { 
    return (gpgme_ctx_t *)memcpy((gpgme_ctx_t *)calloc(1,sizeof(gpgme_ctx_t)),&value,sizeof(gpgme_ctx_t));
  }

  static void delete_gpgme_ctx_t_p(gpgme_ctx_t *obj) { 
    if (obj) free((char*)obj);
  }

  static void gpgme_ctx_t_p_assign(gpgme_ctx_t *obj, gpgme_ctx_t value) {
    *obj = value;
  }

  static gpgme_ctx_t gpgme_ctx_t_p_value(gpgme_ctx_t *obj) {
    return *obj;
  }


  static gpgme_data_t *new_gpgme_data_t_p() { 
    return (gpgme_data_t *)calloc(1,sizeof(gpgme_data_t));
  }
  
  static gpgme_data_t *copy_gpgme_data_t_p(gpgme_data_t value) { 
    return (gpgme_data_t *)memcpy((gpgme_data_t *)calloc(1,sizeof(gpgme_data_t)),&value,sizeof(gpgme_data_t));
  }

  static void delete_gpgme_data_t_p(gpgme_data_t *obj) { 
    if (obj) free((char*)obj);
  }

  static void gpgme_data_t_p_assign(gpgme_data_t *obj, gpgme_data_t value) {
    *obj = value;
  }

  static gpgme_data_t gpgme_data_t_p_value(gpgme_data_t *obj) {
    return *obj;
  }


  static gpgme_key_t *new_gpgme_key_t_p() { 
    return (gpgme_key_t *)calloc(1,sizeof(gpgme_key_t));
  }
  
  static gpgme_key_t *copy_gpgme_key_t_p(gpgme_key_t value) { 
    return (gpgme_key_t *)memcpy((gpgme_key_t *)calloc(1,sizeof(gpgme_key_t)),&value,sizeof(gpgme_key_t));
  }

  static void delete_gpgme_key_t_p(gpgme_key_t *obj) { 
    if (obj) free((char*)obj);
  }

  static void gpgme_key_t_p_assign(gpgme_key_t *obj, gpgme_key_t value) {
    *obj = value;
  }

  static gpgme_key_t gpgme_key_t_p_value(gpgme_key_t *obj) {
    return *obj;
  }


  static gpgme_error_t *new_gpgme_error_t_p() { 
    return (gpgme_error_t *)calloc(1,sizeof(gpgme_error_t));
  }
  
  static gpgme_error_t *copy_gpgme_error_t_p(gpgme_error_t value) { 
    return (gpgme_error_t *)memcpy((gpgme_error_t *)calloc(1,sizeof(gpgme_error_t)),&value,sizeof(gpgme_error_t));
  }

  static void delete_gpgme_error_t_p(gpgme_error_t *obj) { 
    if (obj) free((char*)obj);
  }

  static void gpgme_error_t_p_assign(gpgme_error_t *obj, gpgme_error_t value) {
    *obj = value;
  }

  static gpgme_error_t gpgme_error_t_p_value(gpgme_error_t *obj) {
    return *obj;
  }


  static gpgme_trust_item_t *new_gpgme_trust_item_t_p() { 
    return (gpgme_trust_item_t *)calloc(1,sizeof(gpgme_trust_item_t));
  }
  
  static gpgme_trust_item_t *copy_gpgme_trust_item_t_p(gpgme_trust_item_t value) { 
    return (gpgme_trust_item_t *)memcpy((gpgme_trust_item_t *)calloc(1,sizeof(gpgme_trust_item_t)),&value,sizeof(gpgme_trust_item_t));
  }

  static void delete_gpgme_trust_item_t_p(gpgme_trust_item_t *obj) { 
    if (obj) free((char*)obj);
  }

  static void gpgme_trust_item_t_p_assign(gpgme_trust_item_t *obj, gpgme_trust_item_t value) {
    *obj = value;
  }

  static gpgme_trust_item_t gpgme_trust_item_t_p_value(gpgme_trust_item_t *obj) {
    return *obj;
  }


  static gpgme_engine_info_t *new_gpgme_engine_info_t_p() { 
    return (gpgme_engine_info_t *)calloc(1,sizeof(gpgme_engine_info_t));
  }
  
  static gpgme_engine_info_t *copy_gpgme_engine_info_t_p(gpgme_engine_info_t value) { 
    return (gpgme_engine_info_t *)memcpy((gpgme_engine_info_t *)calloc(1,sizeof(gpgme_engine_info_t)),&value,sizeof(gpgme_engine_info_t));
  }

  static void delete_gpgme_engine_info_t_p(gpgme_engine_info_t *obj) { 
    if (obj) free((char*)obj);
  }

  static void gpgme_engine_info_t_p_assign(gpgme_engine_info_t *obj, gpgme_engine_info_t value) {
    *obj = value;
  }

  static gpgme_engine_info_t gpgme_engine_info_t_p_value(gpgme_engine_info_t *obj) {
    return *obj;
  }


#include <stdio.h>


#include "helpers.h"
#include "private.h"

/* SWIG runtime support for helpers.c  */
PyObject *
_gpg_wrap_gpgme_data_t(gpgme_data_t data)
{
  /*
   * If SWIG is invoked without -builtin, the macro SWIG_NewPointerObj
   * expects a variable named "self".
   *
   * XXX: It is not quite clear why passing NULL as self is okay, but
   * it works with -builtin, and it seems to work just fine without
   * it too.
   */
  PyObject* self = NULL;
  (void) self;
  return SWIG_NewPointerObj(data, SWIGTYPE_p_gpgme_data, 0);
}

gpgme_ctx_t
_gpg_unwrap_gpgme_ctx_t(PyObject *wrapped)
{
  gpgme_ctx_t result;
  if (SWIG_ConvertPtr(wrapped,
                      (void **) &result,
                      SWIGTYPE_p_gpgme_context,
                      SWIG_POINTER_EXCEPTION) == -1)
    return NULL;
  return result;
}

#ifdef __cplusplus
extern "C" {
#endif
SWIGINTERN PyObject *_wrap_gpgme_op_keylist_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) "" ;
  int arg3 = (int) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O|OO:gpgme_op_keylist_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_keylist_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  if (obj1) {
    {
      if (obj1 == Py_None)
      arg2 = NULL;
      else if (PyUnicode_Check(obj1))
      {
        encodedInput2 = PyUnicode_AsUTF8String(obj1);
        if (encodedInput2 == NULL)
        return NULL;
        arg2 = PyBytes_AsString(encodedInput2);
      }
      else if (PyBytes_Check(obj1))
      arg2 = PyBytes_AsString(obj1);
      else {
        PyErr_Format(PyExc_TypeError,
          "arg %d: expected str, bytes, or None, got %s",
          2, obj1->ob_type->tp_name);
        return NULL;
      }
    }
  }
  if (obj2) {
    ecode3 = SWIG_AsVal_int(obj2, &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_keylist_start" "', argument " "3"" of type '" "int""'");
    } 
    arg3 = (int)(val3);
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_keylist_start(arg1,(char const *)arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_seek(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  off_t arg2 ;
  int arg3 = (int) SEEK_SET ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  off_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO|O:gpgme_data_seek",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_seek" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    if (PyLong_Check(obj1))
    
    
    
    arg2 = PyLong_AsLong(obj1);
    
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  if (obj2) {
    ecode3 = SWIG_AsVal_int(obj2, &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_data_seek" "', argument " "3"" of type '" "int""'");
    } 
    arg3 = (int)(val3);
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_seek(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
    
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_sig_notation_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_name_set" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_sig_notation_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->name) free((char*)arg1->name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_sig_notation_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_name_get" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_value_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_sig_notation_value_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_value_set" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_sig_notation_value_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->value) free((char*)arg1->value);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->value = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->value = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_sig_notation_value_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_value_get" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->value);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_flags_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  gpgme_sig_notation_flags_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_sig_notation_flags_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_flags_set" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_sig_notation_flags_set" "', argument " "2"" of type '" "gpgme_sig_notation_flags_t""'");
  } 
  arg2 = (gpgme_sig_notation_flags_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->flags = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_flags_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_sig_notation_flags_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_sig_notation_flags_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_flags_get" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_sig_notation_flags_t) ((arg1)->flags);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_human_readable_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_sig_notation_human_readable_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_human_readable_set" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_sig_notation_human_readable_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->human_readable = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_human_readable_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_sig_notation_human_readable_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_human_readable_get" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->human_readable);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_critical_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_sig_notation_critical_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_critical_set" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_sig_notation_critical_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->critical = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_sig_notation_critical_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_sig_notation_critical_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_sig_notation_critical_get" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->critical);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_sig_notation(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_sig_notation")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_sig_notation *)calloc(1, sizeof(struct _gpgme_sig_notation));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_sig_notation, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_sig_notation(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_sig_notation *arg1 = (struct _gpgme_sig_notation *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_sig_notation",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_sig_notation, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_sig_notation" "', argument " "1"" of type '" "struct _gpgme_sig_notation *""'"); 
  }
  arg1 = (struct _gpgme_sig_notation *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_sig_notation_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_sig_notation, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_err_make(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_err_source_t arg1 ;
  gpgme_err_code_t arg2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_err_make",&obj0,&obj1)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_err_make(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_error(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_err_code_t arg1 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_error",&obj0)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_error(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_err_code(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t arg1 ;
  PyObject * obj0 = 0 ;
  gpgme_err_code_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_err_code",&obj0)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_err_code(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_err_source(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t arg1 ;
  PyObject * obj0 = 0 ;
  gpgme_err_source_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_err_source",&obj0)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_err_source(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_strerror(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t arg1 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_strerror",&obj0)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_strerror(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_strerror_r(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpg_error_t arg1 ;
  char *arg2 = (char *) 0 ;
  size_t arg3 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_strerror_r",&obj0,&obj1)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    {
      long tmp2;
      if (PyLong_Check(obj1))
      tmp2 = PyLong_AsLong(obj1);
      
      else if (PyInt_Check(obj1))
      tmp2 = PyInt_AsLong(obj1);
      
      else
      {
        PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
        return NULL;
      }
      
      if (tmp2 < 0) {
        PyErr_SetString(PyExc_ValueError, "Positive integer expected");
        return NULL;
      }
      arg3 = (size_t) tmp2;
      arg2 = (char *) malloc(arg3+1);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_strerror_r(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  {
    Py_XDECREF(resultobj);   /* Blow away any previous result */
    if (result < 0) {
      /* Check for I/O error */
      free(arg2);
      return PyErr_SetFromErrno(PyExc_RuntimeError);
    }
    resultobj = PyBytes_FromStringAndSize(arg2,result);
    free(arg2);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_strsource(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t arg1 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_strsource",&obj0)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_strsource(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_err_code_from_errno(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  int arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_err_code_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_err_code_from_errno",&obj0)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_err_code_from_errno" "', argument " "1"" of type '" "int""'");
  } 
  arg1 = (int)(val1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_err_code_from_errno(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_err_code_to_errno(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_err_code_t arg1 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_err_code_to_errno",&obj0)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_err_code_to_errno(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_err_code_from_syserror(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_err_code_t result;
  
  if (!PyArg_ParseTuple(args,(char *)":gpgme_err_code_from_syserror")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_err_code_from_syserror();
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_err_set_errno(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  int arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_err_set_errno",&obj0)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_err_set_errno" "', argument " "1"" of type '" "int""'");
  } 
  arg1 = (int)(val1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_err_set_errno(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_err_make_from_errno(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_err_source_t arg1 ;
  int arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_err_make_from_errno",&obj0,&obj1)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_err_make_from_errno" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_err_make_from_errno(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_error_from_errno(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  int arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_error_from_errno",&obj0)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_error_from_errno" "', argument " "1"" of type '" "int""'");
  } 
  arg1 = (int)(val1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_error_from_errno(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_error_from_syserror(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)":gpgme_error_from_syserror")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_error_from_syserror();
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_protocol_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  gpgme_protocol_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_engine_info_protocol_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_protocol_set" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_engine_info_protocol_set" "', argument " "2"" of type '" "gpgme_protocol_t""'");
  } 
  arg2 = (gpgme_protocol_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->protocol = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_protocol_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_protocol_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_engine_info_protocol_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_protocol_get" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_protocol_t) ((arg1)->protocol);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_file_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_engine_info_file_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_file_name_set" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_engine_info_file_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->file_name) free((char*)arg1->file_name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->file_name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->file_name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_file_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_engine_info_file_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_file_name_get" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->file_name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_version_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_engine_info_version_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_version_set" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_engine_info_version_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->version) free((char*)arg1->version);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->version = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->version = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_version_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_engine_info_version_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_version_get" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->version);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_req_version_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_engine_info_req_version_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_req_version_set" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg2) {
      size_t size = strlen((const char *)((const char *)(arg2))) + 1;
      arg1->req_version = (char const *)(char *)memcpy(malloc((size)*sizeof(char)), arg2, sizeof(char)*(size));
    } else {
      arg1->req_version = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_req_version_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_engine_info_req_version_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_req_version_get" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->req_version);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_home_dir_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_engine_info_home_dir_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_home_dir_set" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_engine_info_home_dir_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->home_dir) free((char*)arg1->home_dir);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->home_dir = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->home_dir = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_engine_info_home_dir_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_engine_info_home_dir_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_engine_info_home_dir_get" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->home_dir);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_engine_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_engine_info")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_engine_info *)calloc(1, sizeof(struct _gpgme_engine_info));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_engine_info, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_engine_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_engine_info *arg1 = (struct _gpgme_engine_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_engine_info",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_engine_info" "', argument " "1"" of type '" "struct _gpgme_engine_info *""'"); 
  }
  arg1 = (struct _gpgme_engine_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_engine_info_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_engine_info, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_tofu_info_validity_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_validity_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_validity_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info_validity_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->validity = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_validity_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_validity_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_validity_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->validity);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_policy_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_policy_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_policy_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info_policy_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->policy = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_policy_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_policy_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_policy_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->policy);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info__rfu_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info__rfu_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info__rfu_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info__rfu_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_rfu = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info__rfu_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info__rfu_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info__rfu_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_rfu);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_signcount_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned short arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned short val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_signcount_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_signcount_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_short(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info_signcount_set" "', argument " "2"" of type '" "unsigned short""'");
  } 
  arg2 = (unsigned short)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->signcount = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_signcount_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned short result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_signcount_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_signcount_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned short) ((arg1)->signcount);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_short((unsigned short)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_encrcount_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned short arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned short val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_encrcount_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_encrcount_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_short(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info_encrcount_set" "', argument " "2"" of type '" "unsigned short""'");
  } 
  arg2 = (unsigned short)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->encrcount = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_encrcount_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned short result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_encrcount_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_encrcount_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned short) ((arg1)->encrcount);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_short((unsigned short)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_signfirst_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_signfirst_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_signfirst_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info_signfirst_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->signfirst = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_signfirst_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_signfirst_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_signfirst_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->signfirst);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_signlast_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_signlast_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_signlast_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info_signlast_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->signlast = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_signlast_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_signlast_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_signlast_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->signlast);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_encrfirst_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_encrfirst_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_encrfirst_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info_encrfirst_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->encrfirst = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_encrfirst_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_encrfirst_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_encrfirst_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->encrfirst);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_encrlast_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_encrlast_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_encrlast_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_tofu_info_encrlast_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->encrlast = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_encrlast_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_encrlast_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_encrlast_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->encrlast);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_description_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_tofu_info_description_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_description_set" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_tofu_info_description_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->description) free((char*)arg1->description);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->description = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->description = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_tofu_info_description_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_tofu_info_description_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_tofu_info_description_get" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->description);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_tofu_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_tofu_info")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_tofu_info *)calloc(1, sizeof(struct _gpgme_tofu_info));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_tofu_info, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_tofu_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_tofu_info *arg1 = (struct _gpgme_tofu_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_tofu_info",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_tofu_info, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_tofu_info" "', argument " "1"" of type '" "struct _gpgme_tofu_info *""'"); 
  }
  arg1 = (struct _gpgme_tofu_info *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_tofu_info_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_tofu_info, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_subkey_revoked_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_revoked_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_revoked_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_revoked_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->revoked = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_revoked_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_revoked_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_revoked_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->revoked);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_expired_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_expired_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_expired_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_expired_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->expired = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_expired_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_expired_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_expired_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->expired);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_disabled_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_disabled_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_disabled_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_disabled_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->disabled = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_disabled_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_disabled_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_disabled_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->disabled);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_invalid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_invalid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_invalid_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_invalid_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->invalid = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_invalid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_invalid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_invalid_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->invalid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_can_encrypt_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_can_encrypt_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_can_encrypt_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_can_encrypt_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->can_encrypt = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_can_encrypt_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_can_encrypt_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_can_encrypt_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->can_encrypt);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_can_sign_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_can_sign_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_can_sign_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_can_sign_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->can_sign = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_can_sign_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_can_sign_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_can_sign_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->can_sign);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_can_certify_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_can_certify_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_can_certify_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_can_certify_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->can_certify = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_can_certify_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_can_certify_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_can_certify_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->can_certify);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_secret_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_secret_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_secret_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_secret_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->secret = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_secret_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_secret_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_secret_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->secret);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_can_authenticate_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_can_authenticate_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_can_authenticate_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_can_authenticate_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->can_authenticate = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_can_authenticate_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_can_authenticate_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_can_authenticate_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->can_authenticate);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_is_qualified_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_is_qualified_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_is_qualified_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_is_qualified_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->is_qualified = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_is_qualified_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_is_qualified_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_is_qualified_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->is_qualified);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_is_cardkey_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_is_cardkey_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_is_cardkey_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_is_cardkey_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->is_cardkey = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_is_cardkey_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_is_cardkey_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_is_cardkey_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->is_cardkey);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_is_de_vs_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_is_de_vs_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_is_de_vs_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_is_de_vs_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->is_de_vs = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_is_de_vs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_is_de_vs_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_is_de_vs_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->is_de_vs);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey__unused_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey__unused_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey__unused_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_pubkey_algo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  gpgme_pubkey_algo_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_pubkey_algo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_pubkey_algo_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_pubkey_algo_set" "', argument " "2"" of type '" "gpgme_pubkey_algo_t""'");
  } 
  arg2 = (gpgme_pubkey_algo_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->pubkey_algo = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_pubkey_algo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_pubkey_algo_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_pubkey_algo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_pubkey_algo_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_pubkey_algo_t) ((arg1)->pubkey_algo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_length_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_length_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_length_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_length_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->length = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_length_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_length_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_length_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->length);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_keyid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_keyid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_keyid_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_subkey_keyid_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->keyid) free((char*)arg1->keyid);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->keyid = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->keyid = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_keyid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_keyid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_keyid_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->keyid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey__keyid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[16+1] ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey__keyid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey__keyid_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  res2 = SWIG_AsCharArray(obj1, temp2, 16+1);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_subkey__keyid_set" "', argument " "2"" of type '" "char [16+1]""'");
  }
  arg2 = (char *)(temp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg2) memcpy(arg1->_keyid,arg2,16+1*sizeof(char));
    else memset(arg1->_keyid,0,16+1*sizeof(char));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey__keyid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey__keyid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey__keyid_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)(char *) ((arg1)->_keyid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    size_t size = SWIG_strnlen(result, 16+1);
    
    
    
    resultobj = SWIG_FromCharPtrAndSize(result, size);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_fpr_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_fpr_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_fpr_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_subkey_fpr_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->fpr) free((char*)arg1->fpr);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->fpr = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->fpr = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_fpr_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_fpr_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_fpr_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->fpr);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_timestamp_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_timestamp_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_timestamp_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_timestamp_set" "', argument " "2"" of type '" "long""'");
  } 
  arg2 = (long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->timestamp = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_timestamp_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_timestamp_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_timestamp_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (long) ((arg1)->timestamp);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_long((long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_expires_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_expires_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_expires_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  ecode2 = SWIG_AsVal_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_subkey_expires_set" "', argument " "2"" of type '" "long""'");
  } 
  arg2 = (long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->expires = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_expires_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_expires_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_expires_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (long) ((arg1)->expires);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_long((long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_card_number_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_card_number_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_card_number_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_subkey_card_number_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->card_number) free((char*)arg1->card_number);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->card_number = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->card_number = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_card_number_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_card_number_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_card_number_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->card_number);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_curve_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_curve_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_curve_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_subkey_curve_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->curve) free((char*)arg1->curve);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->curve = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->curve = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_curve_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_curve_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_curve_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->curve);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_keygrip_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_subkey_keygrip_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_keygrip_set" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_subkey_keygrip_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->keygrip) free((char*)arg1->keygrip);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->keygrip = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->keygrip = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_subkey_keygrip_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_subkey_keygrip_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_subkey_keygrip_get" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->keygrip);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_subkey(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_subkey")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_subkey *)calloc(1, sizeof(struct _gpgme_subkey));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_subkey, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_subkey(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_subkey *arg1 = (struct _gpgme_subkey *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_subkey",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_subkey" "', argument " "1"" of type '" "struct _gpgme_subkey *""'"); 
  }
  arg1 = (struct _gpgme_subkey *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_subkey_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_subkey, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_key_sig_revoked_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_revoked_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_revoked_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig_revoked_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->revoked = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_revoked_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_revoked_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_revoked_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->revoked);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_expired_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_expired_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_expired_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig_expired_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->expired = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_expired_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_expired_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_expired_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->expired);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_invalid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_invalid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_invalid_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig_invalid_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->invalid = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_invalid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_invalid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_invalid_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->invalid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_exportable_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_exportable_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_exportable_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig_exportable_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->exportable = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_exportable_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_exportable_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_exportable_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->exportable);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig__unused_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig__unused_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig__unused_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_pubkey_algo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  gpgme_pubkey_algo_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_pubkey_algo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_pubkey_algo_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig_pubkey_algo_set" "', argument " "2"" of type '" "gpgme_pubkey_algo_t""'");
  } 
  arg2 = (gpgme_pubkey_algo_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->pubkey_algo = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_pubkey_algo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_pubkey_algo_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_pubkey_algo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_pubkey_algo_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_pubkey_algo_t) ((arg1)->pubkey_algo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_keyid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_keyid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_keyid_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_sig_keyid_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->keyid) free((char*)arg1->keyid);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->keyid = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->keyid = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_keyid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_keyid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_keyid_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->keyid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig__keyid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[16+1] ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig__keyid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig__keyid_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  res2 = SWIG_AsCharArray(obj1, temp2, 16+1);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_sig__keyid_set" "', argument " "2"" of type '" "char [16+1]""'");
  }
  arg2 = (char *)(temp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg2) memcpy(arg1->_keyid,arg2,16+1*sizeof(char));
    else memset(arg1->_keyid,0,16+1*sizeof(char));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig__keyid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig__keyid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig__keyid_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)(char *) ((arg1)->_keyid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    size_t size = SWIG_strnlen(result, 16+1);
    
    
    
    resultobj = SWIG_FromCharPtrAndSize(result, size);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_timestamp_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_timestamp_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_timestamp_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig_timestamp_set" "', argument " "2"" of type '" "long""'");
  } 
  arg2 = (long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->timestamp = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_timestamp_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_timestamp_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_timestamp_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (long) ((arg1)->timestamp);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_long((long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_expires_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_expires_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_expires_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig_expires_set" "', argument " "2"" of type '" "long""'");
  } 
  arg2 = (long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->expires = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_expires_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_expires_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_expires_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (long) ((arg1)->expires);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_long((long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_status_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_status_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_status_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->status = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_status_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_status_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_status_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->status);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig__obsolete_class_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig__obsolete_class_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig__obsolete_class_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig__obsolete_class_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_obsolete_class = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig__obsolete_class_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig__obsolete_class_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig__obsolete_class_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_obsolete_class);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_uid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_uid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_uid_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_sig_uid_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->uid) free((char*)arg1->uid);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->uid = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->uid = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_uid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_uid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_uid_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->uid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_name_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_sig_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->name) free((char*)arg1->name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_name_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_email_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_email_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_email_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_sig_email_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->email) free((char*)arg1->email);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->email = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->email = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_email_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_email_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_email_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->email);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_comment_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_comment_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_comment_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_sig_comment_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->comment) free((char*)arg1->comment);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->comment = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->comment = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_comment_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_comment_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_comment_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->comment);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_sig_class_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_sig_class_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_sig_class_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_sig_sig_class_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->sig_class = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_sig_class_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_sig_class_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_sig_class_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->sig_class);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_notations_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  gpgme_sig_notation_t arg2 = (gpgme_sig_notation_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig_notations_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_notations_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_sig_notation, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_sig_notations_set" "', argument " "2"" of type '" "gpgme_sig_notation_t""'"); 
  }
  arg2 = (gpgme_sig_notation_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->notations = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig_notations_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_sig_notation_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig_notations_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig_notations_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_sig_notation_t) ((arg1)->notations);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_sig_notation_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_sig_notation,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig__last_notation_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  gpgme_sig_notation_t arg2 = (gpgme_sig_notation_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_sig__last_notation_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig__last_notation_set" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_sig_notation, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_sig__last_notation_set" "', argument " "2"" of type '" "gpgme_sig_notation_t""'"); 
  }
  arg2 = (gpgme_sig_notation_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_last_notation = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_sig__last_notation_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_sig_notation_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_sig__last_notation_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_sig__last_notation_get" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_sig_notation_t) ((arg1)->_last_notation);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_sig_notation_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_sig_notation,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_key_sig(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_key_sig")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_key_sig *)calloc(1, sizeof(struct _gpgme_key_sig));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_key_sig, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_key_sig(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key_sig *arg1 = (struct _gpgme_key_sig *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_key_sig",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key_sig, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_key_sig" "', argument " "1"" of type '" "struct _gpgme_key_sig *""'"); 
  }
  arg1 = (struct _gpgme_key_sig *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_key_sig_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_key_sig, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_user_id_revoked_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_revoked_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_revoked_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_user_id_revoked_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->revoked = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_revoked_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_revoked_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_revoked_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->revoked);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_invalid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_invalid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_invalid_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_user_id_invalid_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->invalid = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_invalid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_invalid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_invalid_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->invalid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id__unused_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_user_id__unused_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id__unused_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_origin_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_origin_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_origin_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_user_id_origin_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->origin = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_origin_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_origin_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_origin_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->origin);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_validity_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  gpgme_validity_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_validity_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_validity_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_user_id_validity_set" "', argument " "2"" of type '" "gpgme_validity_t""'");
  } 
  arg2 = (gpgme_validity_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->validity = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_validity_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_validity_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_validity_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_validity_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_validity_t) ((arg1)->validity);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_uid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_uid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_uid_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_user_id_uid_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->uid) free((char*)arg1->uid);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->uid = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->uid = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_uid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_uid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_uid_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->uid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_name_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_user_id_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->name) free((char*)arg1->name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_name_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_email_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_email_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_email_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_user_id_email_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->email) free((char*)arg1->email);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->email = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->email = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_email_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_email_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_email_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->email);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_comment_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_comment_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_comment_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_user_id_comment_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->comment) free((char*)arg1->comment);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->comment = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->comment = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_comment_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_comment_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_comment_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->comment);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_signatures_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  gpgme_key_sig_t arg2 = (gpgme_key_sig_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_signatures_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_signatures_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key_sig, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_user_id_signatures_set" "', argument " "2"" of type '" "gpgme_key_sig_t""'"); 
  }
  arg2 = (gpgme_key_sig_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->signatures = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_signatures_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_key_sig_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_signatures_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_signatures_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_key_sig_t) ((arg1)->signatures);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_key_sig_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_key_sig,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id__last_keysig_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  gpgme_key_sig_t arg2 = (gpgme_key_sig_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id__last_keysig_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id__last_keysig_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key_sig, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_user_id__last_keysig_set" "', argument " "2"" of type '" "gpgme_key_sig_t""'"); 
  }
  arg2 = (gpgme_key_sig_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_last_keysig = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id__last_keysig_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_key_sig_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id__last_keysig_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id__last_keysig_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_key_sig_t) ((arg1)->_last_keysig);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_key_sig_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_key_sig,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_address_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_address_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_address_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_user_id_address_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->address) free((char*)arg1->address);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->address = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->address = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_address_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_address_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_address_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->address);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_tofu_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  gpgme_tofu_info_t arg2 = (gpgme_tofu_info_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_tofu_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_tofu_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_tofu_info, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_user_id_tofu_set" "', argument " "2"" of type '" "gpgme_tofu_info_t""'"); 
  }
  arg2 = (gpgme_tofu_info_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->tofu = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_tofu_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_tofu_info_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_tofu_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_tofu_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_tofu_info_t) ((arg1)->tofu);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_tofu_info_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_tofu_info,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_last_update_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_user_id_last_update_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_last_update_set" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_user_id_last_update_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->last_update = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_user_id_last_update_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_user_id_last_update_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_user_id_last_update_get" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->last_update);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_user_id(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_user_id")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_user_id *)calloc(1, sizeof(struct _gpgme_user_id));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_user_id, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_user_id(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_user_id *arg1 = (struct _gpgme_user_id *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_user_id",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_user_id, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_user_id" "', argument " "1"" of type '" "struct _gpgme_user_id *""'"); 
  }
  arg1 = (struct _gpgme_user_id *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_user_id_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_user_id, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_key__refs_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key__refs_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key__refs_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key__refs_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_refs = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key__refs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key__refs_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key__refs_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_refs);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_revoked_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_revoked_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_revoked_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_revoked_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->revoked = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_revoked_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_revoked_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_revoked_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->revoked);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_expired_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_expired_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_expired_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_expired_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->expired = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_expired_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_expired_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_expired_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->expired);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_disabled_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_disabled_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_disabled_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_disabled_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->disabled = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_disabled_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_disabled_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_disabled_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->disabled);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_invalid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_invalid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_invalid_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_invalid_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->invalid = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_invalid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_invalid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_invalid_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->invalid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_can_encrypt_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_can_encrypt_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_can_encrypt_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_can_encrypt_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->can_encrypt = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_can_encrypt_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_can_encrypt_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_can_encrypt_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->can_encrypt);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_can_sign_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_can_sign_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_can_sign_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_can_sign_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->can_sign = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_can_sign_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_can_sign_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_can_sign_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->can_sign);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_can_certify_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_can_certify_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_can_certify_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_can_certify_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->can_certify = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_can_certify_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_can_certify_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_can_certify_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->can_certify);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_secret_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_secret_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_secret_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_secret_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->secret = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_secret_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_secret_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_secret_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->secret);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_can_authenticate_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_can_authenticate_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_can_authenticate_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_can_authenticate_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->can_authenticate = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_can_authenticate_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_can_authenticate_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_can_authenticate_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->can_authenticate);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_is_qualified_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_is_qualified_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_is_qualified_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_is_qualified_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->is_qualified = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_is_qualified_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_is_qualified_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_is_qualified_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->is_qualified);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key__unused_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key__unused_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key__unused_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_origin_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_origin_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_origin_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_origin_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->origin = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_origin_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_origin_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_origin_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->origin);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_protocol_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  gpgme_protocol_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_protocol_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_protocol_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_protocol_set" "', argument " "2"" of type '" "gpgme_protocol_t""'");
  } 
  arg2 = (gpgme_protocol_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->protocol = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_protocol_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_protocol_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_protocol_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_protocol_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_protocol_t) ((arg1)->protocol);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_issuer_serial_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_issuer_serial_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_issuer_serial_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_issuer_serial_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->issuer_serial) free((char*)arg1->issuer_serial);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->issuer_serial = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->issuer_serial = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_issuer_serial_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_issuer_serial_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_issuer_serial_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->issuer_serial);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_issuer_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_issuer_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_issuer_name_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_issuer_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->issuer_name) free((char*)arg1->issuer_name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->issuer_name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->issuer_name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_issuer_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_issuer_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_issuer_name_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->issuer_name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_chain_id_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_chain_id_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_chain_id_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_chain_id_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->chain_id) free((char*)arg1->chain_id);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->chain_id = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->chain_id = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_chain_id_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_chain_id_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_chain_id_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->chain_id);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_owner_trust_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  gpgme_validity_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_owner_trust_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_owner_trust_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_owner_trust_set" "', argument " "2"" of type '" "gpgme_validity_t""'");
  } 
  arg2 = (gpgme_validity_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->owner_trust = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_owner_trust_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_validity_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_owner_trust_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_owner_trust_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_validity_t) ((arg1)->owner_trust);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_subkeys_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  gpgme_subkey_t arg2 = (gpgme_subkey_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_subkeys_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_subkeys_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_subkey, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_subkeys_set" "', argument " "2"" of type '" "gpgme_subkey_t""'"); 
  }
  arg2 = (gpgme_subkey_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->subkeys = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_subkeys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_subkey_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_subkeys_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_subkeys_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_subkey_t) ((arg1)->subkeys);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_subkey_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_subkey,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_uids_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  gpgme_user_id_t arg2 = (gpgme_user_id_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_uids_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_uids_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_user_id, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_uids_set" "', argument " "2"" of type '" "gpgme_user_id_t""'"); 
  }
  arg2 = (gpgme_user_id_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->uids = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_uids_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_user_id_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_uids_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_uids_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_user_id_t) ((arg1)->uids);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_user_id_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_user_id,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key__last_subkey_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  gpgme_subkey_t arg2 = (gpgme_subkey_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key__last_subkey_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key__last_subkey_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_subkey, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key__last_subkey_set" "', argument " "2"" of type '" "gpgme_subkey_t""'"); 
  }
  arg2 = (gpgme_subkey_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_last_subkey = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key__last_subkey_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_subkey_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key__last_subkey_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key__last_subkey_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_subkey_t) ((arg1)->_last_subkey);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_subkey_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_subkey,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key__last_uid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  gpgme_user_id_t arg2 = (gpgme_user_id_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key__last_uid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key__last_uid_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_user_id, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key__last_uid_set" "', argument " "2"" of type '" "gpgme_user_id_t""'"); 
  }
  arg2 = (gpgme_user_id_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_last_uid = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key__last_uid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_user_id_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key__last_uid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key__last_uid_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_user_id_t) ((arg1)->_last_uid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_user_id_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_user_id,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_keylist_mode_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  gpgme_keylist_mode_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_keylist_mode_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_keylist_mode_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_keylist_mode_set" "', argument " "2"" of type '" "gpgme_keylist_mode_t""'");
  } 
  arg2 = (gpgme_keylist_mode_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->keylist_mode = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_keylist_mode_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_keylist_mode_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_keylist_mode_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_keylist_mode_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_keylist_mode_t) ((arg1)->keylist_mode);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_fpr_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_fpr_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_fpr_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_key_fpr_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->fpr) free((char*)arg1->fpr);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->fpr = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->fpr = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_fpr_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_fpr_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_fpr_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->fpr);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_last_update_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_key_last_update_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_last_update_set" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_key_last_update_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->last_update = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_key_last_update_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_key_last_update_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_key_last_update_get" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->last_update);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_key(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_key")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_key *)calloc(1, sizeof(struct _gpgme_key));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_key, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_key(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_key *arg1 = (struct _gpgme_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_key",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_key" "', argument " "1"" of type '" "struct _gpgme_key *""'"); 
  }
  arg1 = (struct _gpgme_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_key_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_key, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_invalid_key_fpr_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_invalid_key *arg1 = (struct _gpgme_invalid_key *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_invalid_key_fpr_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_invalid_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_invalid_key_fpr_set" "', argument " "1"" of type '" "struct _gpgme_invalid_key *""'"); 
  }
  arg1 = (struct _gpgme_invalid_key *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_invalid_key_fpr_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->fpr) free((char*)arg1->fpr);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->fpr = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->fpr = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_invalid_key_fpr_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_invalid_key *arg1 = (struct _gpgme_invalid_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_invalid_key_fpr_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_invalid_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_invalid_key_fpr_get" "', argument " "1"" of type '" "struct _gpgme_invalid_key *""'"); 
  }
  arg1 = (struct _gpgme_invalid_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->fpr);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_invalid_key_reason_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_invalid_key *arg1 = (struct _gpgme_invalid_key *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_invalid_key_reason_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_invalid_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_invalid_key_reason_set" "', argument " "1"" of type '" "struct _gpgme_invalid_key *""'"); 
  }
  arg1 = (struct _gpgme_invalid_key *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->reason = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_invalid_key_reason_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_invalid_key *arg1 = (struct _gpgme_invalid_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_invalid_key_reason_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_invalid_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_invalid_key_reason_get" "', argument " "1"" of type '" "struct _gpgme_invalid_key *""'"); 
  }
  arg1 = (struct _gpgme_invalid_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->reason);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_invalid_key(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_invalid_key *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_invalid_key")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_invalid_key *)calloc(1, sizeof(struct _gpgme_invalid_key));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_invalid_key, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_invalid_key(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_invalid_key *arg1 = (struct _gpgme_invalid_key *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_invalid_key",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_invalid_key, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_invalid_key" "', argument " "1"" of type '" "struct _gpgme_invalid_key *""'"); 
  }
  arg1 = (struct _gpgme_invalid_key *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_invalid_key_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_invalid_key, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t *arg1 = (gpgme_ctx_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_new",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_new" "', argument " "1"" of type '" "gpgme_ctx_t *""'"); 
  }
  arg1 = (gpgme_ctx_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_new(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_release(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_release",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_release" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_release(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_ctx_flag(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject *encodedInput3 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_set_ctx_flag",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_ctx_flag" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_set_ctx_flag(arg1,(char const *)arg2,(char const *)arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_ctx_flag(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_get_ctx_flag",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_ctx_flag" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_get_ctx_flag(arg1,(char const *)arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_protocol(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_protocol_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_protocol",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_protocol" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_protocol" "', argument " "2"" of type '" "gpgme_protocol_t""'");
  } 
  arg2 = (gpgme_protocol_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_set_protocol(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_protocol(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_protocol_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_protocol",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_protocol" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_protocol_t)gpgme_get_protocol(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_sub_protocol(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_protocol_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_sub_protocol",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_sub_protocol" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_sub_protocol" "', argument " "2"" of type '" "gpgme_protocol_t""'");
  } 
  arg2 = (gpgme_protocol_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_set_sub_protocol(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_sub_protocol(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_protocol_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_sub_protocol",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_sub_protocol" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_protocol_t)gpgme_get_sub_protocol(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_protocol_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_protocol_t arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_protocol_name",&obj0)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_get_protocol_name" "', argument " "1"" of type '" "gpgme_protocol_t""'");
  } 
  arg1 = (gpgme_protocol_t)(val1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_get_protocol_name(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_armor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_armor",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_armor" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_armor" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_set_armor(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_armor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_armor",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_armor" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_get_armor(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_textmode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_textmode",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_textmode" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_textmode" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_set_textmode(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_textmode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_textmode",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_textmode" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_get_textmode(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_offline(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_offline",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_offline" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_offline" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_set_offline(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_offline(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_offline",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_offline" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_get_offline(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_include_certs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_include_certs",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_include_certs" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_include_certs" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_set_include_certs(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_include_certs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_include_certs",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_include_certs" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_get_include_certs(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_keylist_mode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_keylist_mode_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_keylist_mode",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_keylist_mode" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_keylist_mode" "', argument " "2"" of type '" "gpgme_keylist_mode_t""'");
  } 
  arg2 = (gpgme_keylist_mode_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_set_keylist_mode(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_keylist_mode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_keylist_mode_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_keylist_mode",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_keylist_mode" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_keylist_mode_t)gpgme_get_keylist_mode(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_pinentry_mode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_pinentry_mode_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_pinentry_mode",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_pinentry_mode" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_pinentry_mode" "', argument " "2"" of type '" "gpgme_pinentry_mode_t""'");
  } 
  arg2 = (gpgme_pinentry_mode_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_set_pinentry_mode(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_pinentry_mode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_pinentry_mode_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_pinentry_mode",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_pinentry_mode" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_pinentry_mode_t)gpgme_get_pinentry_mode(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_passphrase_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_passphrase_cb_t arg2 = (gpgme_passphrase_cb_t) 0 ;
  void *arg3 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_set_passphrase_cb",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_passphrase_cb" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_set_passphrase_cb" "', argument " "2"" of type '" "gpgme_passphrase_cb_t""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_set_passphrase_cb" "', argument " "3"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_set_passphrase_cb(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_passphrase_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_passphrase_cb_t *arg2 = (gpgme_passphrase_cb_t *) 0 ;
  void **arg3 = (void **) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_get_passphrase_cb",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_passphrase_cb" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_get_passphrase_cb" "', argument " "2"" of type '" "gpgme_passphrase_cb_t *""'"); 
  }
  arg2 = (gpgme_passphrase_cb_t *)(argp2);
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_p_void, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_get_passphrase_cb" "', argument " "3"" of type '" "void **""'"); 
  }
  arg3 = (void **)(argp3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_get_passphrase_cb(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_progress_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_progress_cb_t arg2 = (gpgme_progress_cb_t) 0 ;
  void *arg3 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_set_progress_cb",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_progress_cb" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_p_q_const__char_int_int_int__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_set_progress_cb" "', argument " "2"" of type '" "gpgme_progress_cb_t""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_set_progress_cb" "', argument " "3"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_set_progress_cb(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_progress_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_progress_cb_t *arg2 = (gpgme_progress_cb_t *) 0 ;
  void **arg3 = (void **) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_get_progress_cb",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_progress_cb" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_p_f_p_void_p_q_const__char_int_int_int__void, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_get_progress_cb" "', argument " "2"" of type '" "gpgme_progress_cb_t *""'"); 
  }
  arg2 = (gpgme_progress_cb_t *)(argp2);
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_p_void, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_get_progress_cb" "', argument " "3"" of type '" "void **""'"); 
  }
  arg3 = (void **)(argp3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_get_progress_cb(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_status_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_status_cb_t arg2 = (gpgme_status_cb_t) 0 ;
  void *arg3 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_set_status_cb",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_status_cb" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_set_status_cb" "', argument " "2"" of type '" "gpgme_status_cb_t""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_set_status_cb" "', argument " "3"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_set_status_cb(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_status_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_status_cb_t *arg2 = (gpgme_status_cb_t *) 0 ;
  void **arg3 = (void **) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_get_status_cb",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_status_cb" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_get_status_cb" "', argument " "2"" of type '" "gpgme_status_cb_t *""'"); 
  }
  arg2 = (gpgme_status_cb_t *)(argp2);
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_p_void, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_get_status_cb" "', argument " "3"" of type '" "void **""'"); 
  }
  arg3 = (void **)(argp3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_get_status_cb(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_locale(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  char *arg3 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_set_locale",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_locale" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_set_locale" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_set_locale(arg1,arg2,(char const *)arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_ctx_get_engine_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_engine_info_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_ctx_get_engine_info",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_ctx_get_engine_info" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_engine_info_t)gpgme_ctx_get_engine_info(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_engine_info_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    if (resultobj == NULL)
    return NULL;	/* raise */
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *fragile, *o;
      fragile = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_engine_info,
        0 );
      if (fragile == NULL)
      {
        Py_DECREF(resultobj);
        return NULL;	/* raise */
      }
      o = _gpg_wrap_result(fragile, "EngineInfo");
      Py_DECREF(fragile);
      if (o == NULL)
      {
        Py_DECREF(resultobj);
        return NULL;	/* raise */
      }
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_ctx_set_engine_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_protocol_t arg2 ;
  char *arg3 = (char *) 0 ;
  char *arg4 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  PyObject *encodedInput4 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_ctx_set_engine_info",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_ctx_set_engine_info" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_ctx_set_engine_info" "', argument " "2"" of type '" "gpgme_protocol_t""'");
  } 
  arg2 = (gpgme_protocol_t)(val2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj3 == Py_None)
    arg4 = NULL;
    else if (PyUnicode_Check(obj3))
    {
      encodedInput4 = PyUnicode_AsUTF8String(obj3);
      if (encodedInput4 == NULL)
      return NULL;
      arg4 = PyBytes_AsString(encodedInput4);
    }
    else if (PyBytes_Check(obj3))
    arg4 = PyBytes_AsString(obj3);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        4, obj3->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_ctx_set_engine_info(arg1,arg2,(char const *)arg3,(char const *)arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    Py_XDECREF(encodedInput4);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  {
    Py_XDECREF(encodedInput4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_signers_clear(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_signers_clear",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_signers_clear" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_signers_clear(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_signers_add(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) (gpgme_key_t)0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_signers_add",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_signers_add" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_signers_add" "', argument " "2"" of type '" "gpgme_key_t const""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_signers_add(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_signers_count(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) (gpgme_ctx_t)0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_signers_count",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_signers_count" "', argument " "1"" of type '" "gpgme_ctx_t const""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int)gpgme_signers_count(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_signers_enum(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) (gpgme_ctx_t)0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_key_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_signers_enum",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_signers_enum" "', argument " "1"" of type '" "gpgme_ctx_t const""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_signers_enum" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_key_t)gpgme_signers_enum(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_key, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_sig_notation_clear(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_sig_notation_clear",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_sig_notation_clear" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_sig_notation_clear(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_sig_notation_add(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  gpgme_sig_notation_flags_t arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject *encodedInput3 = NULL ;
  unsigned int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_sig_notation_add",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_sig_notation_add" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_sig_notation_add" "', argument " "4"" of type '" "gpgme_sig_notation_flags_t""'");
  } 
  arg4 = (gpgme_sig_notation_flags_t)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_sig_notation_add(arg1,(char const *)arg2,(char const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_sig_notation_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_sig_notation_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_sig_notation_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_sig_notation_get" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_sig_notation_t)gpgme_sig_notation_get(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_sig_notation_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_sig_notation,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_sender(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_sender",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_sender" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_set_sender(arg1,(char const *)arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_sender(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_sender",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_sender" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_get_sender(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_event_done_data_err_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_event_done_data *arg1 = (struct gpgme_io_event_done_data *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_io_event_done_data_err_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_event_done_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_event_done_data_err_set" "', argument " "1"" of type '" "struct gpgme_io_event_done_data *""'"); 
  }
  arg1 = (struct gpgme_io_event_done_data *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->err = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_event_done_data_err_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_event_done_data *arg1 = (struct gpgme_io_event_done_data *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_io_event_done_data_err_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_event_done_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_event_done_data_err_get" "', argument " "1"" of type '" "struct gpgme_io_event_done_data *""'"); 
  }
  arg1 = (struct gpgme_io_event_done_data *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->err);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_event_done_data_op_err_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_event_done_data *arg1 = (struct gpgme_io_event_done_data *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_io_event_done_data_op_err_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_event_done_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_event_done_data_op_err_set" "', argument " "1"" of type '" "struct gpgme_io_event_done_data *""'"); 
  }
  arg1 = (struct gpgme_io_event_done_data *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->op_err = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_event_done_data_op_err_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_event_done_data *arg1 = (struct gpgme_io_event_done_data *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_io_event_done_data_op_err_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_event_done_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_event_done_data_op_err_get" "', argument " "1"" of type '" "struct gpgme_io_event_done_data *""'"); 
  }
  arg1 = (struct gpgme_io_event_done_data *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->op_err);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_io_event_done_data(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_event_done_data *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_io_event_done_data")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct gpgme_io_event_done_data *)calloc(1, sizeof(struct gpgme_io_event_done_data));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_io_event_done_data, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_io_event_done_data(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_event_done_data *arg1 = (struct gpgme_io_event_done_data *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_io_event_done_data",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_event_done_data, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_io_event_done_data" "', argument " "1"" of type '" "struct gpgme_io_event_done_data *""'"); 
  }
  arg1 = (struct gpgme_io_event_done_data *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *gpgme_io_event_done_data_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_gpgme_io_event_done_data, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_io_cbs_add_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  gpgme_register_io_cb_t arg2 = (gpgme_register_io_cb_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_io_cbs_add_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_add_set" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_io_cbs_add_set" "', argument " "2"" of type '" "gpgme_register_io_cb_t""'"); 
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->add = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_add_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_register_io_cb_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_io_cbs_add_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_add_get" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_register_io_cb_t) ((arg1)->add);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewFunctionPtrObj((void *)(result), SWIGTYPE_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_add_priv_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  void *arg2 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_io_cbs_add_priv_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_add_priv_set" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  res2 = SWIG_ConvertPtr(obj1,SWIG_as_voidptrptr(&arg2), 0, SWIG_POINTER_DISOWN);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_io_cbs_add_priv_set" "', argument " "2"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->add_priv = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_add_priv_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  void *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_io_cbs_add_priv_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_add_priv_get" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (void *) ((arg1)->add_priv);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_remove_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  gpgme_remove_io_cb_t arg2 = (gpgme_remove_io_cb_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_io_cbs_remove_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_remove_set" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_io_cbs_remove_set" "', argument " "2"" of type '" "gpgme_remove_io_cb_t""'"); 
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->remove = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_remove_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_remove_io_cb_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_io_cbs_remove_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_remove_get" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_remove_io_cb_t) ((arg1)->remove);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewFunctionPtrObj((void *)(result), SWIGTYPE_p_f_p_void__void);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_event_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  gpgme_event_io_cb_t arg2 = (gpgme_event_io_cb_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_io_cbs_event_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_event_set" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_enum_gpgme_event_io_t_p_void__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_io_cbs_event_set" "', argument " "2"" of type '" "gpgme_event_io_cb_t""'"); 
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->event = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_event_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_event_io_cb_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_io_cbs_event_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_event_get" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_event_io_cb_t) ((arg1)->event);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewFunctionPtrObj((void *)(result), SWIGTYPE_p_f_p_void_enum_gpgme_event_io_t_p_void__void);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_event_priv_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  void *arg2 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_io_cbs_event_priv_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_event_priv_set" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  res2 = SWIG_ConvertPtr(obj1,SWIG_as_voidptrptr(&arg2), 0, SWIG_POINTER_DISOWN);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_io_cbs_event_priv_set" "', argument " "2"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->event_priv = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_cbs_event_priv_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  void *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_io_cbs_event_priv_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_io_cbs_event_priv_get" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (void *) ((arg1)->event_priv);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_io_cbs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_io_cbs")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct gpgme_io_cbs *)calloc(1, sizeof(struct gpgme_io_cbs));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_io_cbs, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_io_cbs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_io_cbs *arg1 = (struct gpgme_io_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_io_cbs",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_io_cbs, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_io_cbs" "', argument " "1"" of type '" "struct gpgme_io_cbs *""'"); 
  }
  arg1 = (struct gpgme_io_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *gpgme_io_cbs_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_gpgme_io_cbs, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_set_io_cbs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_io_cbs_t arg2 = (gpgme_io_cbs_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_io_cbs",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_set_io_cbs" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_set_io_cbs" "', argument " "2"" of type '" "gpgme_io_cbs_t""'"); 
  }
  arg2 = (gpgme_io_cbs_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_set_io_cbs(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_io_cbs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_io_cbs_t arg2 = (gpgme_io_cbs_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_get_io_cbs",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_io_cbs" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_io_cbs, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_get_io_cbs" "', argument " "2"" of type '" "gpgme_io_cbs_t""'"); 
  }
  arg2 = (gpgme_io_cbs_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_get_io_cbs(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_read(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  int arg1 ;
  void *arg2 = (void *) 0 ;
  size_t arg3 ;
  int val1 ;
  int ecode1 = 0 ;
  int res2 ;
  size_t val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  ssize_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_io_read",&obj0,&obj1,&obj2)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_io_read" "', argument " "1"" of type '" "int""'");
  } 
  arg1 = (int)(val1);
  res2 = SWIG_ConvertPtr(obj1,SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_io_read" "', argument " "2"" of type '" "void *""'"); 
  }
  ecode3 = SWIG_AsVal_size_t(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_io_read" "', argument " "3"" of type '" "size_t""'");
  } 
  arg3 = (size_t)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_io_read(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_write(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  int arg1 ;
  void *arg2 = (void *) 0 ;
  size_t arg3 ;
  int val1 ;
  int ecode1 = 0 ;
  int res2 ;
  size_t val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  ssize_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_io_write",&obj0,&obj1,&obj2)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_io_write" "', argument " "1"" of type '" "int""'");
  } 
  arg1 = (int)(val1);
  res2 = SWIG_ConvertPtr(obj1,SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_io_write" "', argument " "2"" of type '" "void const *""'"); 
  }
  ecode3 = SWIG_AsVal_size_t(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_io_write" "', argument " "3"" of type '" "size_t""'");
  } 
  arg3 = (size_t)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_io_write(arg1,(void const *)arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_io_writen(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  int arg1 ;
  void *arg2 = (void *) 0 ;
  size_t arg3 ;
  int val1 ;
  int ecode1 = 0 ;
  int res2 ;
  size_t val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_io_writen",&obj0,&obj1,&obj2)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_io_writen" "', argument " "1"" of type '" "int""'");
  } 
  arg1 = (int)(val1);
  res2 = SWIG_ConvertPtr(obj1,SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_io_writen" "', argument " "2"" of type '" "void const *""'"); 
  }
  ecode3 = SWIG_AsVal_size_t(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_io_writen" "', argument " "3"" of type '" "size_t""'");
  } 
  arg3 = (size_t)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_io_writen(arg1,(void const *)arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_wait(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_error_t *arg2 = (gpgme_error_t *) 0 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_ctx_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_wait",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_wait" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_wait" "', argument " "2"" of type '" "gpgme_error_t *""'"); 
  }
  arg2 = (gpgme_error_t *)(argp2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_wait" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_ctx_t)gpgme_wait(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_context, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_wait_ext(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_error_t *arg2 = (gpgme_error_t *) 0 ;
  gpgme_error_t *arg3 = (gpgme_error_t *) 0 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_ctx_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_wait_ext",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_wait_ext" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_wait_ext" "', argument " "2"" of type '" "gpgme_error_t *""'"); 
  }
  arg2 = (gpgme_error_t *)(argp2);
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_wait_ext" "', argument " "3"" of type '" "gpgme_error_t *""'"); 
  }
  arg3 = (gpgme_error_t *)(argp3);
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_wait_ext" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_ctx_t)gpgme_wait_ext(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_context, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_cancel(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_cancel",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_cancel" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_cancel(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_cancel_async(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_cancel_async",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_cancel_async" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_cancel_async(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_cbs_read_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  gpgme_data_read_cb_t arg2 = (gpgme_data_read_cb_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_cbs_read_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_cbs_read_set" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_p_void_size_t__ssize_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_data_cbs_read_set" "', argument " "2"" of type '" "gpgme_data_read_cb_t""'"); 
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->read = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_cbs_read_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_read_cb_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_cbs_read_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_cbs_read_get" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_read_cb_t) ((arg1)->read);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewFunctionPtrObj((void *)(result), SWIGTYPE_p_f_p_void_p_void_size_t__ssize_t);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_cbs_write_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  gpgme_data_write_cb_t arg2 = (gpgme_data_write_cb_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_cbs_write_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_cbs_write_set" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_p_q_const__void_size_t__ssize_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_data_cbs_write_set" "', argument " "2"" of type '" "gpgme_data_write_cb_t""'"); 
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->write = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_cbs_write_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_write_cb_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_cbs_write_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_cbs_write_get" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_write_cb_t) ((arg1)->write);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewFunctionPtrObj((void *)(result), SWIGTYPE_p_f_p_void_p_q_const__void_size_t__ssize_t);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_cbs_seek_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  gpgme_data_seek_cb_t arg2 = (gpgme_data_seek_cb_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_cbs_seek_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_cbs_seek_set" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_off_t_int__off_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_data_cbs_seek_set" "', argument " "2"" of type '" "gpgme_data_seek_cb_t""'"); 
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->seek = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_cbs_seek_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_seek_cb_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_cbs_seek_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_cbs_seek_get" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_seek_cb_t) ((arg1)->seek);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewFunctionPtrObj((void *)(result), SWIGTYPE_p_f_p_void_off_t_int__off_t);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_cbs_release_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  gpgme_data_release_cb_t arg2 = (gpgme_data_release_cb_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_cbs_release_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_cbs_release_set" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_data_cbs_release_set" "', argument " "2"" of type '" "gpgme_data_release_cb_t""'"); 
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->release = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_cbs_release_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_release_cb_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_cbs_release_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_cbs_release_get" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_release_cb_t) ((arg1)->release);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewFunctionPtrObj((void *)(result), SWIGTYPE_p_f_p_void__void);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_data_cbs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_data_cbs")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct gpgme_data_cbs *)calloc(1, sizeof(struct gpgme_data_cbs));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_data_cbs, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_data_cbs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_data_cbs *arg1 = (struct gpgme_data_cbs *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_data_cbs",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data_cbs, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_data_cbs" "', argument " "1"" of type '" "struct gpgme_data_cbs *""'"); 
  }
  arg1 = (struct gpgme_data_cbs *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *gpgme_data_cbs_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_gpgme_data_cbs, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_data_read(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  void *arg2 = (void *) 0 ;
  size_t arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  ssize_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_read",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_read" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    {
      long tmp2;
      if (PyLong_Check(obj1))
      tmp2 = PyLong_AsLong(obj1);
      
      else if (PyInt_Check(obj1))
      tmp2 = PyInt_AsLong(obj1);
      
      else
      {
        PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
        return NULL;
      }
      
      if (tmp2 < 0) {
        PyErr_SetString(PyExc_ValueError, "Positive integer expected");
        return NULL;
      }
      arg3 = (size_t) tmp2;
      arg2 = (void *) malloc(arg3+1);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_read(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(resultobj);   /* Blow away any previous result */
    if (result < 0) {
      /* Check for I/O error */
      free(arg2);
      return PyErr_SetFromErrno(PyExc_RuntimeError);
    }
    resultobj = PyBytes_FromStringAndSize(arg2,result);
    free(arg2);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_write(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  void *arg2 = (void *) 0 ;
  size_t arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  ssize_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_write",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_write" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    Py_ssize_t ssize;
    
    if (obj1 == Py_None)
    arg2 = NULL, arg3 = 0;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      if (PyBytes_AsStringAndSize(encodedInput2, (char **) &arg2, &ssize) == -1)
      {
        Py_DECREF(encodedInput2);
        return NULL;
      }
    }
    else if (PyBytes_Check(obj1))
    PyBytes_AsStringAndSize(obj1, (char **) &arg2, &ssize);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
    
    if (! arg2)
    arg3 = 0;
    else
    {
      assert (ssize >= 0);
      arg3 = (size_t) ssize;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_write(arg1,(void const *)arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_new",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_release(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_release",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_release" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_data_release(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new_from_mem(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  char *arg2 = (char *) 0 ;
  size_t arg3 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  size_t val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_data_new_from_mem",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new_from_mem" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  ecode3 = SWIG_AsVal_size_t(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_data_new_from_mem" "', argument " "3"" of type '" "size_t""'");
  } 
  arg3 = (size_t)(val3);
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_data_new_from_mem" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new_from_mem(arg1,(char const *)arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_release_and_get_mem(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  size_t *arg2 = (size_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_release_and_get_mem",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_release_and_get_mem" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_size_t, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_data_release_and_get_mem" "', argument " "2"" of type '" "size_t *""'"); 
  }
  arg2 = (size_t *)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_data_release_and_get_mem(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  gpgme_free(result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_free(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  void *arg1 = (void *) 0 ;
  int res1 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_free",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0,SWIG_as_voidptrptr(&arg1), 0, 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_free" "', argument " "1"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_free(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new_from_cbs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  gpgme_data_cbs_t arg2 = (gpgme_data_cbs_t) 0 ;
  void *arg3 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int res3 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_data_new_from_cbs",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new_from_cbs" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_data_cbs, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_data_new_from_cbs" "', argument " "2"" of type '" "gpgme_data_cbs_t""'"); 
  }
  arg2 = (gpgme_data_cbs_t)(argp2);
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_data_new_from_cbs" "', argument " "3"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new_from_cbs(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new_from_fd(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_new_from_fd",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new_from_fd" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_data_new_from_fd" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new_from_fd(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new_from_stream(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  FILE *arg2 = (FILE *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_new_from_stream",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new_from_stream" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_FILE, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_data_new_from_stream" "', argument " "2"" of type '" "FILE *""'"); 
  }
  arg2 = (FILE *)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new_from_stream(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new_from_estream(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  gpgrt_stream_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_new_from_estream",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new_from_estream" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  {
    res2 = SWIG_ConvertPtr(obj1, &argp2, SWIGTYPE_p_gpgrt_stream_t,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_data_new_from_estream" "', argument " "2"" of type '" "gpgrt_stream_t""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gpgme_data_new_from_estream" "', argument " "2"" of type '" "gpgrt_stream_t""'");
    } else {
      arg2 = *((gpgrt_stream_t *)(argp2));
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new_from_estream(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_get_encoding(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_encoding_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_get_encoding",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_get_encoding" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_encoding_t)gpgme_data_get_encoding(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_set_encoding(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  gpgme_data_encoding_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_set_encoding",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_set_encoding" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_data_set_encoding" "', argument " "2"" of type '" "gpgme_data_encoding_t""'");
  } 
  arg2 = (gpgme_data_encoding_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_set_encoding(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_get_file_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_get_file_name",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_get_file_name" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_data_get_file_name(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_set_file_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_set_file_name",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_set_file_name" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_set_file_name(arg1,(char const *)arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_set_flag(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject *encodedInput3 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpg_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_data_set_flag",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_set_flag" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_set_flag(arg1,(char const *)arg2,(char const *)arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_identify(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_data_type_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_identify",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_identify" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_data_identify" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_type_t)gpgme_data_identify(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new_from_file(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  char *arg2 = (char *) 0 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_data_new_from_file",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new_from_file" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_data_new_from_file" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new_from_file(arg1,(char const *)arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new_from_filepart(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  char *arg2 = (char *) 0 ;
  FILE *arg3 = (FILE *) 0 ;
  off_t arg4 ;
  size_t arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  size_t val5 ;
  int ecode5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_data_new_from_filepart",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new_from_filepart" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_FILE, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_data_new_from_filepart" "', argument " "3"" of type '" "FILE *""'"); 
  }
  arg3 = (FILE *)(argp3);
  {
    if (PyLong_Check(obj3))
    
    
    
    arg4 = PyLong_AsLong(obj3);
    
    
    else if (PyInt_Check(obj3))
    arg4 = PyInt_AsLong(obj3);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  ecode5 = SWIG_AsVal_size_t(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_data_new_from_filepart" "', argument " "5"" of type '" "size_t""'");
  } 
  arg5 = (size_t)(val5);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new_from_filepart(arg1,(char const *)arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_rewind(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_rewind",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_rewind" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_rewind(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_key(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  gpgme_key_t *arg3 = (gpgme_key_t *) 0 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_get_key",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_key" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_get_key" "', argument " "3"" of type '" "gpgme_key_t *""'"); 
  }
  arg3 = (gpgme_key_t *)(argp3);
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_get_key" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_get_key(arg1,(char const *)arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_from_uid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t *arg1 = (gpgme_key_t *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_key_from_uid",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_from_uid" "', argument " "1"" of type '" "gpgme_key_t *""'"); 
  }
  arg1 = (gpgme_key_t *)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_key_from_uid(arg1,(char const *)arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_ref(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t arg1 = (gpgme_key_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_key_ref",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_ref" "', argument " "1"" of type '" "gpgme_key_t""'"); 
  }
  arg1 = (gpgme_key_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_key_ref(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_unref(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t arg1 = (gpgme_key_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_key_unref",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_unref" "', argument " "1"" of type '" "gpgme_key_t""'"); 
  }
  arg1 = (gpgme_key_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_key_unref(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_release(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t arg1 = (gpgme_key_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_key_release",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_release" "', argument " "1"" of type '" "gpgme_key_t""'"); 
  }
  arg1 = (gpgme_key_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_key_release(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_encrypt_result_invalid_recipients_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_encrypt_result *arg1 = (struct _gpgme_op_encrypt_result *) 0 ;
  gpgme_invalid_key_t arg2 = (gpgme_invalid_key_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_encrypt_result_invalid_recipients_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_encrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_encrypt_result_invalid_recipients_set" "', argument " "1"" of type '" "struct _gpgme_op_encrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_encrypt_result *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_invalid_key, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_encrypt_result_invalid_recipients_set" "', argument " "2"" of type '" "gpgme_invalid_key_t""'"); 
  }
  arg2 = (gpgme_invalid_key_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->invalid_recipients = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_encrypt_result_invalid_recipients_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_encrypt_result *arg1 = (struct _gpgme_op_encrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_invalid_key_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_encrypt_result_invalid_recipients_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_encrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_encrypt_result_invalid_recipients_get" "', argument " "1"" of type '" "struct _gpgme_op_encrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_encrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_invalid_key_t) ((arg1)->invalid_recipients);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_invalid_key_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_invalid_key,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_encrypt_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_encrypt_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_encrypt_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_encrypt_result *)calloc(1, sizeof(struct _gpgme_op_encrypt_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_encrypt_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_encrypt_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_encrypt_result *arg1 = (struct _gpgme_op_encrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_encrypt_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_encrypt_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_encrypt_result" "', argument " "1"" of type '" "struct _gpgme_op_encrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_encrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_encrypt_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_encrypt_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_encrypt_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_encrypt_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_encrypt_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_encrypt_result_t)gpgme_op_encrypt_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    PyObject *fragile;
    fragile = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_encrypt_result,
      0 );
    resultobj = _gpg_wrap_result(fragile, "EncryptResult");
    Py_DECREF(fragile);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_encrypt_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  gpgme_encrypt_flags_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_encrypt_start",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_encrypt_start" "', argument " "3"" of type '" "gpgme_encrypt_flags_t""'");
  } 
  arg3 = (gpgme_encrypt_flags_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_encrypt_start(arg1,arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_encrypt(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  gpgme_encrypt_flags_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_encrypt",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_encrypt" "', argument " "3"" of type '" "gpgme_encrypt_flags_t""'");
  } 
  arg3 = (gpgme_encrypt_flags_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_encrypt(arg1,arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_encrypt_ext_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  char *arg3 = (char *) 0 ;
  gpgme_encrypt_flags_t arg4 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  gpgme_data_t arg6 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput3 = NULL ;
  int val4 ;
  int ecode4 = 0 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  gpgme_data_t wrapper6 = NULL ;
  PyObject *bytesio6 = NULL ;
  Py_buffer view6 ;
  int have_view6 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOOO:gpgme_op_encrypt_ext_start",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt_ext_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_encrypt_ext_start" "', argument " "4"" of type '" "gpgme_encrypt_flags_t""'");
  } 
  arg4 = (gpgme_encrypt_flags_t)(val4);
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper6 object, we will store it in
         wrapperN, where N is 6.  Here in this fragment, SWIG will
         automatically append 6.  */
    memset(&view6, 0, sizeof view6);
    if (obj5 == Py_None)
    arg6 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj5, 6, &wrapper6,
        &bytesio6, &view6);
      if (pypointer == NULL)
      return NULL;
      have_view6 = !! view6.obj;
      
      /* input = obj5, 1 = arg6, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg6, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_encrypt_ext_start(arg1,arg2,(char const *)arg3,arg4,arg5,arg6);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_encrypt_ext(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  char *arg3 = (char *) 0 ;
  gpgme_encrypt_flags_t arg4 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  gpgme_data_t arg6 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput3 = NULL ;
  int val4 ;
  int ecode4 = 0 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  gpgme_data_t wrapper6 = NULL ;
  PyObject *bytesio6 = NULL ;
  Py_buffer view6 ;
  int have_view6 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOOO:gpgme_op_encrypt_ext",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt_ext" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_encrypt_ext" "', argument " "4"" of type '" "gpgme_encrypt_flags_t""'");
  } 
  arg4 = (gpgme_encrypt_flags_t)(val4);
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper6 object, we will store it in
         wrapperN, where N is 6.  Here in this fragment, SWIG will
         automatically append 6.  */
    memset(&view6, 0, sizeof view6);
    if (obj5 == Py_None)
    arg6 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj5, 6, &wrapper6,
        &bytesio6, &view6);
      if (pypointer == NULL)
      return NULL;
      have_view6 = !! view6.obj;
      
      /* input = obj5, 1 = arg6, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg6, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_encrypt_ext(arg1,arg2,(char const *)arg3,arg4,arg5,arg6);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_encrypt_sign_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  gpgme_encrypt_flags_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_encrypt_sign_start",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt_sign_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_encrypt_sign_start" "', argument " "3"" of type '" "gpgme_encrypt_flags_t""'");
  } 
  arg3 = (gpgme_encrypt_flags_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_encrypt_sign_start(arg1,arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_encrypt_sign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  gpgme_encrypt_flags_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_encrypt_sign",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt_sign" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_encrypt_sign" "', argument " "3"" of type '" "gpgme_encrypt_flags_t""'");
  } 
  arg3 = (gpgme_encrypt_flags_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_encrypt_sign(arg1,arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_encrypt_sign_ext_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  char *arg3 = (char *) 0 ;
  gpgme_encrypt_flags_t arg4 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  gpgme_data_t arg6 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput3 = NULL ;
  int val4 ;
  int ecode4 = 0 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  gpgme_data_t wrapper6 = NULL ;
  PyObject *bytesio6 = NULL ;
  Py_buffer view6 ;
  int have_view6 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOOO:gpgme_op_encrypt_sign_ext_start",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt_sign_ext_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_encrypt_sign_ext_start" "', argument " "4"" of type '" "gpgme_encrypt_flags_t""'");
  } 
  arg4 = (gpgme_encrypt_flags_t)(val4);
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper6 object, we will store it in
         wrapperN, where N is 6.  Here in this fragment, SWIG will
         automatically append 6.  */
    memset(&view6, 0, sizeof view6);
    if (obj5 == Py_None)
    arg6 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj5, 6, &wrapper6,
        &bytesio6, &view6);
      if (pypointer == NULL)
      return NULL;
      have_view6 = !! view6.obj;
      
      /* input = obj5, 1 = arg6, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg6, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_encrypt_sign_ext_start(arg1,arg2,(char const *)arg3,arg4,arg5,arg6);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_encrypt_sign_ext(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  char *arg3 = (char *) 0 ;
  gpgme_encrypt_flags_t arg4 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  gpgme_data_t arg6 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput3 = NULL ;
  int val4 ;
  int ecode4 = 0 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  gpgme_data_t wrapper6 = NULL ;
  PyObject *bytesio6 = NULL ;
  Py_buffer view6 ;
  int have_view6 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOOO:gpgme_op_encrypt_sign_ext",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_encrypt_sign_ext" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_encrypt_sign_ext" "', argument " "4"" of type '" "gpgme_encrypt_flags_t""'");
  } 
  arg4 = (gpgme_encrypt_flags_t)(val4);
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper6 object, we will store it in
         wrapperN, where N is 6.  Here in this fragment, SWIG will
         automatically append 6.  */
    memset(&view6, 0, sizeof view6);
    if (obj5 == Py_None)
    arg6 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj5, 6, &wrapper6,
        &bytesio6, &view6);
      if (pypointer == NULL)
      return NULL;
      have_view6 = !! view6.obj;
      
      /* input = obj5, 1 = arg6, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg6, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_encrypt_sign_ext(arg1,arg2,(char const *)arg3,arg4,arg5,arg6);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_recipient_keyid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_recipient_keyid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_recipient_keyid_set" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_recipient_keyid_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->keyid) free((char*)arg1->keyid);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->keyid = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->keyid = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_recipient_keyid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_recipient_keyid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_recipient_keyid_get" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->keyid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_recipient__keyid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[16+1] ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_recipient__keyid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_recipient__keyid_set" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  res2 = SWIG_AsCharArray(obj1, temp2, 16+1);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_recipient__keyid_set" "', argument " "2"" of type '" "char [16+1]""'");
  }
  arg2 = (char *)(temp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg2) memcpy(arg1->_keyid,arg2,16+1*sizeof(char));
    else memset(arg1->_keyid,0,16+1*sizeof(char));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_recipient__keyid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_recipient__keyid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_recipient__keyid_get" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)(char *) ((arg1)->_keyid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    size_t size = SWIG_strnlen(result, 16+1);
    
    
    
    resultobj = SWIG_FromCharPtrAndSize(result, size);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_recipient_pubkey_algo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  gpgme_pubkey_algo_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_recipient_pubkey_algo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_recipient_pubkey_algo_set" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_recipient_pubkey_algo_set" "', argument " "2"" of type '" "gpgme_pubkey_algo_t""'");
  } 
  arg2 = (gpgme_pubkey_algo_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->pubkey_algo = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_recipient_pubkey_algo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_pubkey_algo_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_recipient_pubkey_algo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_recipient_pubkey_algo_get" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_pubkey_algo_t) ((arg1)->pubkey_algo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_recipient_status_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_recipient_status_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_recipient_status_set" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->status = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_recipient_status_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_recipient_status_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_recipient_status_get" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->status);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_recipient(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_recipient")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_recipient *)calloc(1, sizeof(struct _gpgme_recipient));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_recipient, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_recipient(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_recipient *arg1 = (struct _gpgme_recipient *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_recipient",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_recipient, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_recipient" "', argument " "1"" of type '" "struct _gpgme_recipient *""'"); 
  }
  arg1 = (struct _gpgme_recipient *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_recipient_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_recipient, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_unsupported_algorithm_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_unsupported_algorithm_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_unsupported_algorithm_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_decrypt_result_unsupported_algorithm_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->unsupported_algorithm) free((char*)arg1->unsupported_algorithm);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->unsupported_algorithm = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->unsupported_algorithm = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_unsupported_algorithm_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_unsupported_algorithm_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_unsupported_algorithm_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->unsupported_algorithm);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_wrong_key_usage_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_wrong_key_usage_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_wrong_key_usage_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_decrypt_result_wrong_key_usage_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->wrong_key_usage = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_wrong_key_usage_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_wrong_key_usage_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_wrong_key_usage_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->wrong_key_usage);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_is_de_vs_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_is_de_vs_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_is_de_vs_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_decrypt_result_is_de_vs_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->is_de_vs = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_is_de_vs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_is_de_vs_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_is_de_vs_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->is_de_vs);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_is_mime_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_is_mime_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_is_mime_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_decrypt_result_is_mime_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->is_mime = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_is_mime_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_is_mime_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_is_mime_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->is_mime);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_legacy_cipher_nomdc_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_legacy_cipher_nomdc_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_legacy_cipher_nomdc_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_decrypt_result_legacy_cipher_nomdc_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->legacy_cipher_nomdc = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_legacy_cipher_nomdc_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_legacy_cipher_nomdc_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_legacy_cipher_nomdc_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->legacy_cipher_nomdc);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result__unused_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_decrypt_result__unused_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result__unused_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_recipients_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  gpgme_recipient_t arg2 = (gpgme_recipient_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_recipients_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_recipients_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_recipient, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_decrypt_result_recipients_set" "', argument " "2"" of type '" "gpgme_recipient_t""'"); 
  }
  arg2 = (gpgme_recipient_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->recipients = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_recipients_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_recipient_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_recipients_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_recipients_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_recipient_t) ((arg1)->recipients);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_recipient_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_recipient,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_file_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_file_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_file_name_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_decrypt_result_file_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->file_name) free((char*)arg1->file_name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->file_name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->file_name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_file_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_file_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_file_name_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->file_name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_session_key_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_session_key_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_session_key_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_decrypt_result_session_key_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->session_key) free((char*)arg1->session_key);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->session_key = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->session_key = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_session_key_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_session_key_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_session_key_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->session_key);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_symkey_algo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_decrypt_result_symkey_algo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_symkey_algo_set" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_decrypt_result_symkey_algo_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->symkey_algo) free((char*)arg1->symkey_algo);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->symkey_algo = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->symkey_algo = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_decrypt_result_symkey_algo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_decrypt_result_symkey_algo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_decrypt_result_symkey_algo_get" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->symkey_algo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_decrypt_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_decrypt_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_decrypt_result *)calloc(1, sizeof(struct _gpgme_op_decrypt_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_decrypt_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_decrypt_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_decrypt_result *arg1 = (struct _gpgme_op_decrypt_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_decrypt_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_decrypt_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_decrypt_result" "', argument " "1"" of type '" "struct _gpgme_op_decrypt_result *""'"); 
  }
  arg1 = (struct _gpgme_op_decrypt_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_decrypt_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_decrypt_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_decrypt_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_decrypt_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_decrypt_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_decrypt_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_decrypt_result_t)gpgme_op_decrypt_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    PyObject *fragile;
    fragile = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_decrypt_result,
      0 );
    resultobj = _gpg_wrap_result(fragile, "DecryptResult");
    Py_DECREF(fragile);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_decrypt_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_decrypt_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_decrypt_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_decrypt_start(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_decrypt(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_decrypt",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_decrypt" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_decrypt(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_decrypt_verify_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_decrypt_verify_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_decrypt_verify_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_decrypt_verify_start(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_decrypt_verify(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_decrypt_verify",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_decrypt_verify" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_decrypt_verify(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_decrypt_ext_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_decrypt_flags_t arg2 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_decrypt_ext_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_decrypt_ext_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_op_decrypt_ext_start" "', argument " "2"" of type '" "gpgme_decrypt_flags_t""'");
  } 
  arg2 = (gpgme_decrypt_flags_t)(val2);
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_decrypt_ext_start(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_decrypt_ext(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_decrypt_flags_t arg2 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_decrypt_ext",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_decrypt_ext" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_op_decrypt_ext" "', argument " "2"" of type '" "gpgme_decrypt_flags_t""'");
  } 
  arg2 = (gpgme_decrypt_flags_t)(val2);
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_decrypt_ext(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_type_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  gpgme_sig_mode_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_new_signature_type_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_type_set" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_new_signature_type_set" "', argument " "2"" of type '" "gpgme_sig_mode_t""'");
  } 
  arg2 = (gpgme_sig_mode_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->type = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_type_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_sig_mode_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_new_signature_type_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_type_get" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_sig_mode_t) ((arg1)->type);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_pubkey_algo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  gpgme_pubkey_algo_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_new_signature_pubkey_algo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_pubkey_algo_set" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_new_signature_pubkey_algo_set" "', argument " "2"" of type '" "gpgme_pubkey_algo_t""'");
  } 
  arg2 = (gpgme_pubkey_algo_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->pubkey_algo = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_pubkey_algo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_pubkey_algo_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_new_signature_pubkey_algo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_pubkey_algo_get" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_pubkey_algo_t) ((arg1)->pubkey_algo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_hash_algo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  gpgme_hash_algo_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_new_signature_hash_algo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_hash_algo_set" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_new_signature_hash_algo_set" "', argument " "2"" of type '" "gpgme_hash_algo_t""'");
  } 
  arg2 = (gpgme_hash_algo_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->hash_algo = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_hash_algo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_hash_algo_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_new_signature_hash_algo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_hash_algo_get" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_hash_algo_t) ((arg1)->hash_algo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature__obsolete_class_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_new_signature__obsolete_class_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature__obsolete_class_set" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_new_signature__obsolete_class_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_obsolete_class = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature__obsolete_class_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_new_signature__obsolete_class_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature__obsolete_class_get" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->_obsolete_class);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_timestamp_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_new_signature_timestamp_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_timestamp_set" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  ecode2 = SWIG_AsVal_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_new_signature_timestamp_set" "', argument " "2"" of type '" "long""'");
  } 
  arg2 = (long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->timestamp = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_timestamp_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_new_signature_timestamp_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_timestamp_get" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (long) ((arg1)->timestamp);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_long((long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_fpr_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_new_signature_fpr_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_fpr_set" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_new_signature_fpr_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->fpr) free((char*)arg1->fpr);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->fpr = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->fpr = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_fpr_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_new_signature_fpr_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_fpr_get" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->fpr);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature__obsolete_class_2_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_new_signature__obsolete_class_2_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature__obsolete_class_2_set" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_new_signature__obsolete_class_2_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_obsolete_class_2 = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature__obsolete_class_2_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_new_signature__obsolete_class_2_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature__obsolete_class_2_get" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_obsolete_class_2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_sig_class_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_new_signature_sig_class_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_sig_class_set" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_new_signature_sig_class_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->sig_class = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_new_signature_sig_class_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_new_signature_sig_class_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_new_signature_sig_class_get" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->sig_class);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_new_signature(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_new_signature")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_new_signature *)calloc(1, sizeof(struct _gpgme_new_signature));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_new_signature, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_new_signature(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_new_signature *arg1 = (struct _gpgme_new_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_new_signature",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_new_signature, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_new_signature" "', argument " "1"" of type '" "struct _gpgme_new_signature *""'"); 
  }
  arg1 = (struct _gpgme_new_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_new_signature_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_new_signature, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_op_sign_result_invalid_signers_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_sign_result *arg1 = (struct _gpgme_op_sign_result *) 0 ;
  gpgme_invalid_key_t arg2 = (gpgme_invalid_key_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_sign_result_invalid_signers_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_sign_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_sign_result_invalid_signers_set" "', argument " "1"" of type '" "struct _gpgme_op_sign_result *""'"); 
  }
  arg1 = (struct _gpgme_op_sign_result *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_invalid_key, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_sign_result_invalid_signers_set" "', argument " "2"" of type '" "gpgme_invalid_key_t""'"); 
  }
  arg2 = (gpgme_invalid_key_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->invalid_signers = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_sign_result_invalid_signers_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_sign_result *arg1 = (struct _gpgme_op_sign_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_invalid_key_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_sign_result_invalid_signers_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_sign_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_sign_result_invalid_signers_get" "', argument " "1"" of type '" "struct _gpgme_op_sign_result *""'"); 
  }
  arg1 = (struct _gpgme_op_sign_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_invalid_key_t) ((arg1)->invalid_signers);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_invalid_key_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_invalid_key,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_sign_result_signatures_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_sign_result *arg1 = (struct _gpgme_op_sign_result *) 0 ;
  gpgme_new_signature_t arg2 = (gpgme_new_signature_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_sign_result_signatures_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_sign_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_sign_result_signatures_set" "', argument " "1"" of type '" "struct _gpgme_op_sign_result *""'"); 
  }
  arg1 = (struct _gpgme_op_sign_result *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_new_signature, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_sign_result_signatures_set" "', argument " "2"" of type '" "gpgme_new_signature_t""'"); 
  }
  arg2 = (gpgme_new_signature_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->signatures = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_sign_result_signatures_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_sign_result *arg1 = (struct _gpgme_op_sign_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_new_signature_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_sign_result_signatures_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_sign_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_sign_result_signatures_get" "', argument " "1"" of type '" "struct _gpgme_op_sign_result *""'"); 
  }
  arg1 = (struct _gpgme_op_sign_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_new_signature_t) ((arg1)->signatures);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_new_signature_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_new_signature,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_sign_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_sign_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_sign_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_sign_result *)calloc(1, sizeof(struct _gpgme_op_sign_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_sign_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_sign_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_sign_result *arg1 = (struct _gpgme_op_sign_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_sign_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_sign_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_sign_result" "', argument " "1"" of type '" "struct _gpgme_op_sign_result *""'"); 
  }
  arg1 = (struct _gpgme_op_sign_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_sign_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_sign_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_sign_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_sign_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_sign_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_sign_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_sign_result_t)gpgme_op_sign_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    PyObject *fragile;
    fragile = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_sign_result,
      0 );
    resultobj = _gpg_wrap_result(fragile, "SignResult");
    Py_DECREF(fragile);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_sign_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  gpgme_sig_mode_t arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_sign_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_sign_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_sign_start" "', argument " "4"" of type '" "gpgme_sig_mode_t""'");
  } 
  arg4 = (gpgme_sig_mode_t)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_sign_start(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_sign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  gpgme_sig_mode_t arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_sign",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_sign" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_sign" "', argument " "4"" of type '" "gpgme_sig_mode_t""'");
  } 
  arg4 = (gpgme_sig_mode_t)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_sign(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_summary_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  gpgme_sigsum_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_summary_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_summary_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_summary_set" "', argument " "2"" of type '" "gpgme_sigsum_t""'");
  } 
  arg2 = (gpgme_sigsum_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->summary = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_summary_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_sigsum_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_summary_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_summary_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_sigsum_t) ((arg1)->summary);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_fpr_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_fpr_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_fpr_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_signature_fpr_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->fpr) free((char*)arg1->fpr);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->fpr = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->fpr = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_fpr_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_fpr_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_fpr_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->fpr);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_status_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_status_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_status_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->status = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_status_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_status_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_status_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->status);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_notations_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  gpgme_sig_notation_t arg2 = (gpgme_sig_notation_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_notations_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_notations_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_sig_notation, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_signature_notations_set" "', argument " "2"" of type '" "gpgme_sig_notation_t""'"); 
  }
  arg2 = (gpgme_sig_notation_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->notations = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_notations_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_sig_notation_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_notations_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_notations_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_sig_notation_t) ((arg1)->notations);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_sig_notation_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_sig_notation,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_timestamp_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_timestamp_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_timestamp_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_timestamp_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->timestamp = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_timestamp_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_timestamp_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_timestamp_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->timestamp);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_exp_timestamp_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_exp_timestamp_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_exp_timestamp_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_exp_timestamp_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->exp_timestamp = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_exp_timestamp_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_exp_timestamp_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_exp_timestamp_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->exp_timestamp);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_wrong_key_usage_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_wrong_key_usage_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_wrong_key_usage_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_wrong_key_usage_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->wrong_key_usage = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_wrong_key_usage_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_wrong_key_usage_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_wrong_key_usage_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->wrong_key_usage);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_pka_trust_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_pka_trust_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_pka_trust_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_pka_trust_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->pka_trust = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_pka_trust_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_pka_trust_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_pka_trust_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->pka_trust);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_chain_model_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_chain_model_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_chain_model_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_chain_model_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->chain_model = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_chain_model_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_chain_model_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_chain_model_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->chain_model);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_is_de_vs_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_is_de_vs_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_is_de_vs_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_is_de_vs_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->is_de_vs = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_is_de_vs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_is_de_vs_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_is_de_vs_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->is_de_vs);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature__unused_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature__unused_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature__unused_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_validity_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  gpgme_validity_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_validity_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_validity_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_validity_set" "', argument " "2"" of type '" "gpgme_validity_t""'");
  } 
  arg2 = (gpgme_validity_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->validity = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_validity_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_validity_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_validity_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_validity_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_validity_t) ((arg1)->validity);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_validity_reason_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_validity_reason_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_validity_reason_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->validity_reason = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_validity_reason_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_validity_reason_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_validity_reason_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->validity_reason);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_pubkey_algo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  gpgme_pubkey_algo_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_pubkey_algo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_pubkey_algo_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_pubkey_algo_set" "', argument " "2"" of type '" "gpgme_pubkey_algo_t""'");
  } 
  arg2 = (gpgme_pubkey_algo_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->pubkey_algo = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_pubkey_algo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_pubkey_algo_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_pubkey_algo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_pubkey_algo_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_pubkey_algo_t) ((arg1)->pubkey_algo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_hash_algo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  gpgme_hash_algo_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_hash_algo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_hash_algo_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_signature_hash_algo_set" "', argument " "2"" of type '" "gpgme_hash_algo_t""'");
  } 
  arg2 = (gpgme_hash_algo_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->hash_algo = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_hash_algo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_hash_algo_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_hash_algo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_hash_algo_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_hash_algo_t) ((arg1)->hash_algo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_pka_address_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_pka_address_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_pka_address_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_signature_pka_address_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->pka_address) free((char*)arg1->pka_address);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->pka_address = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->pka_address = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_pka_address_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_pka_address_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_pka_address_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->pka_address);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_key_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_signature_key_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_key_set" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_signature_key_set" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->key = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_signature_key_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_key_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_signature_key_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_signature_key_get" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_key_t) ((arg1)->key);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_key, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_signature(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_signature")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_signature *)calloc(1, sizeof(struct _gpgme_signature));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_signature, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_signature(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_signature *arg1 = (struct _gpgme_signature *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_signature",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_signature, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_signature" "', argument " "1"" of type '" "struct _gpgme_signature *""'"); 
  }
  arg1 = (struct _gpgme_signature *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_signature_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_signature, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_op_verify_result_signatures_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  gpgme_signature_t arg2 = (gpgme_signature_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_verify_result_signatures_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_verify_result_signatures_set" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_signature, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_verify_result_signatures_set" "', argument " "2"" of type '" "gpgme_signature_t""'"); 
  }
  arg2 = (gpgme_signature_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->signatures = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_verify_result_signatures_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_signature_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_verify_result_signatures_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_verify_result_signatures_get" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_signature_t) ((arg1)->signatures);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_signature_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_signature,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_verify_result_file_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_verify_result_file_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_verify_result_file_name_set" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_verify_result_file_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->file_name) free((char*)arg1->file_name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->file_name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->file_name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_verify_result_file_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_verify_result_file_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_verify_result_file_name_get" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->file_name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_verify_result_is_mime_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_verify_result_is_mime_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_verify_result_is_mime_set" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_verify_result_is_mime_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->is_mime = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_verify_result_is_mime_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_verify_result_is_mime_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_verify_result_is_mime_get" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->is_mime);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_verify_result__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_verify_result__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_verify_result__unused_set" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_verify_result__unused_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_verify_result__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_verify_result__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_verify_result__unused_get" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_verify_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_verify_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_verify_result *)calloc(1, sizeof(struct _gpgme_op_verify_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_verify_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_verify_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_verify_result *arg1 = (struct _gpgme_op_verify_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_verify_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_verify_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_verify_result" "', argument " "1"" of type '" "struct _gpgme_op_verify_result *""'"); 
  }
  arg1 = (struct _gpgme_op_verify_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_verify_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_verify_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_verify_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_verify_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_verify_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_verify_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_verify_result_t)gpgme_op_verify_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    PyObject *fragile;
    fragile = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_verify_result,
      0 );
    resultobj = _gpg_wrap_result(fragile, "VerifyResult");
    Py_DECREF(fragile);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_verify_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_verify_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_verify_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_verify_start(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_verify(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_verify",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_verify" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_verify(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_import_status_fpr_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_import_status *arg1 = (struct _gpgme_import_status *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_import_status_fpr_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_import_status, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_import_status_fpr_set" "', argument " "1"" of type '" "struct _gpgme_import_status *""'"); 
  }
  arg1 = (struct _gpgme_import_status *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_import_status_fpr_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->fpr) free((char*)arg1->fpr);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->fpr = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->fpr = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_import_status_fpr_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_import_status *arg1 = (struct _gpgme_import_status *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_import_status_fpr_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_import_status, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_import_status_fpr_get" "', argument " "1"" of type '" "struct _gpgme_import_status *""'"); 
  }
  arg1 = (struct _gpgme_import_status *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->fpr);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_import_status_result_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_import_status *arg1 = (struct _gpgme_import_status *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_import_status_result_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_import_status, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_import_status_result_set" "', argument " "1"" of type '" "struct _gpgme_import_status *""'"); 
  }
  arg1 = (struct _gpgme_import_status *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->result = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_import_status_result_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_import_status *arg1 = (struct _gpgme_import_status *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_import_status_result_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_import_status, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_import_status_result_get" "', argument " "1"" of type '" "struct _gpgme_import_status *""'"); 
  }
  arg1 = (struct _gpgme_import_status *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->result);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_import_status_status_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_import_status *arg1 = (struct _gpgme_import_status *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_import_status_status_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_import_status, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_import_status_status_set" "', argument " "1"" of type '" "struct _gpgme_import_status *""'"); 
  }
  arg1 = (struct _gpgme_import_status *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_import_status_status_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->status = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_import_status_status_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_import_status *arg1 = (struct _gpgme_import_status *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_import_status_status_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_import_status, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_import_status_status_get" "', argument " "1"" of type '" "struct _gpgme_import_status *""'"); 
  }
  arg1 = (struct _gpgme_import_status *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->status);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_import_status(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_import_status *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_import_status")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_import_status *)calloc(1, sizeof(struct _gpgme_import_status));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_import_status, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_import_status(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_import_status *arg1 = (struct _gpgme_import_status *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_import_status",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_import_status, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_import_status" "', argument " "1"" of type '" "struct _gpgme_import_status *""'"); 
  }
  arg1 = (struct _gpgme_import_status *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_import_status_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_import_status, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap__gpgme_op_import_result_considered_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_considered_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_considered_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_considered_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->considered = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_considered_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_considered_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_considered_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->considered);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_no_user_id_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_no_user_id_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_no_user_id_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_no_user_id_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->no_user_id = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_no_user_id_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_no_user_id_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_no_user_id_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->no_user_id);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_imported_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_imported_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_imported_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_imported_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->imported = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_imported_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_imported_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_imported_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->imported);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_imported_rsa_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_imported_rsa_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_imported_rsa_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_imported_rsa_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->imported_rsa = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_imported_rsa_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_imported_rsa_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_imported_rsa_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->imported_rsa);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_unchanged_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_unchanged_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_unchanged_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_unchanged_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->unchanged = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_unchanged_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_unchanged_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_unchanged_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->unchanged);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_new_user_ids_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_new_user_ids_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_new_user_ids_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_new_user_ids_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->new_user_ids = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_new_user_ids_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_new_user_ids_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_new_user_ids_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->new_user_ids);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_new_sub_keys_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_new_sub_keys_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_new_sub_keys_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_new_sub_keys_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->new_sub_keys = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_new_sub_keys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_new_sub_keys_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_new_sub_keys_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->new_sub_keys);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_new_signatures_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_new_signatures_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_new_signatures_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_new_signatures_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->new_signatures = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_new_signatures_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_new_signatures_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_new_signatures_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->new_signatures);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_new_revocations_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_new_revocations_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_new_revocations_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_new_revocations_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->new_revocations = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_new_revocations_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_new_revocations_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_new_revocations_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->new_revocations);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_secret_read_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_secret_read_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_secret_read_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_secret_read_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->secret_read = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_secret_read_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_secret_read_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_secret_read_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->secret_read);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_secret_imported_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_secret_imported_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_secret_imported_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_secret_imported_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->secret_imported = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_secret_imported_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_secret_imported_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_secret_imported_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->secret_imported);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_secret_unchanged_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_secret_unchanged_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_secret_unchanged_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_secret_unchanged_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->secret_unchanged = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_secret_unchanged_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_secret_unchanged_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_secret_unchanged_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->secret_unchanged);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_skipped_new_keys_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_skipped_new_keys_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_skipped_new_keys_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_skipped_new_keys_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->skipped_new_keys = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_skipped_new_keys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_skipped_new_keys_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_skipped_new_keys_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->skipped_new_keys);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_not_imported_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_not_imported_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_not_imported_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_not_imported_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->not_imported = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_not_imported_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_not_imported_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_not_imported_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->not_imported);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_imports_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  gpgme_import_status_t arg2 = (gpgme_import_status_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_imports_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_imports_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_import_status, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_import_result_imports_set" "', argument " "2"" of type '" "gpgme_import_status_t""'"); 
  }
  arg2 = (gpgme_import_status_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->imports = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_imports_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_import_status_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_imports_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_imports_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_import_status_t) ((arg1)->imports);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_import_status_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_import_status,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_skipped_v3_keys_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_import_result_skipped_v3_keys_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_skipped_v3_keys_set" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_import_result_skipped_v3_keys_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->skipped_v3_keys = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_import_result_skipped_v3_keys_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_import_result_skipped_v3_keys_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_import_result_skipped_v3_keys_get" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->skipped_v3_keys);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_import_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_import_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_import_result *)calloc(1, sizeof(struct _gpgme_op_import_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_import_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_import_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_import_result *arg1 = (struct _gpgme_op_import_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_import_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_import_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_import_result" "', argument " "1"" of type '" "struct _gpgme_op_import_result *""'"); 
  }
  arg1 = (struct _gpgme_op_import_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_import_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_import_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_import_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_import_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_import_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_import_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_import_result_t)gpgme_op_import_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    PyObject *fragile;
    fragile = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_import_result,
      0 );
    resultobj = _gpg_wrap_result(fragile, "ImportResult");
    Py_DECREF(fragile);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_import_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_op_import_start",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_import_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_import_start(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_import(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_op_import",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_import" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_import(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_import_keys_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_op_import_keys_start",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_import_keys_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_import_keys_start(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_import_keys(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_op_import_keys",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_import_keys" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_import_keys(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_export_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  gpgme_export_mode_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_export_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_export_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_export_start" "', argument " "3"" of type '" "gpgme_export_mode_t""'");
  } 
  arg3 = (gpgme_export_mode_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_export_start(arg1,(char const *)arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_export(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  gpgme_export_mode_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_export",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_export" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_export" "', argument " "3"" of type '" "gpgme_export_mode_t""'");
  } 
  arg3 = (gpgme_export_mode_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_export(arg1,(char const *)arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_export_ext_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char **arg2 ;
  gpgme_export_mode_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *vector2 = NULL ;
  size_t size2 ;
  PyObject **pyVector2 = NULL ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_export_ext_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_export_ext_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* Check if is a list */
    if (PyList_Check(obj1)) {
      size_t i, j;
      size2 = PyList_Size(obj1);
      arg2 = (char **) (vector2 = malloc((size2+1) * sizeof(char *)));
      pyVector2 = calloc(sizeof *pyVector2, size2);
      
      for (i = 0; i < size2; i++) {
        PyObject *o = PyList_GetItem(obj1,i);
        if (PyUnicode_Check(o))
        {
          pyVector2[i] = PyUnicode_AsUTF8String(o);
          if (pyVector2[i] == NULL)
          {
            free(vector2);
            for (j = 0; j < i; j++)
            Py_XDECREF(pyVector2[j]);
            return NULL;
          }
          arg2[i] = PyBytes_AsString(pyVector2[i]);
        }
        else if (PyString_Check(o))
        arg2[i] = PyString_AsString(o);
        else {
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only str or bytes, got %s "
            "at position %d",
            2, o->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
      }
      arg2[i] = NULL;
    } else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected a list of str or bytes, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_export_ext_start" "', argument " "3"" of type '" "gpgme_export_mode_t""'");
  } 
  arg3 = (gpgme_export_mode_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_export_ext_start(arg1,(char const *(*))arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    size_t i;
    free(vector2);
    for (i = 0; i < size2; i++)
    Py_XDECREF(pyVector2[i]);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    size_t i;
    free(vector2);
    for (i = 0; i < size2; i++)
    Py_XDECREF(pyVector2[i]);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_export_ext(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char **arg2 ;
  gpgme_export_mode_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *vector2 = NULL ;
  size_t size2 ;
  PyObject **pyVector2 = NULL ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_export_ext",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_export_ext" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* Check if is a list */
    if (PyList_Check(obj1)) {
      size_t i, j;
      size2 = PyList_Size(obj1);
      arg2 = (char **) (vector2 = malloc((size2+1) * sizeof(char *)));
      pyVector2 = calloc(sizeof *pyVector2, size2);
      
      for (i = 0; i < size2; i++) {
        PyObject *o = PyList_GetItem(obj1,i);
        if (PyUnicode_Check(o))
        {
          pyVector2[i] = PyUnicode_AsUTF8String(o);
          if (pyVector2[i] == NULL)
          {
            free(vector2);
            for (j = 0; j < i; j++)
            Py_XDECREF(pyVector2[j]);
            return NULL;
          }
          arg2[i] = PyBytes_AsString(pyVector2[i]);
        }
        else if (PyString_Check(o))
        arg2[i] = PyString_AsString(o);
        else {
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only str or bytes, got %s "
            "at position %d",
            2, o->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
      }
      arg2[i] = NULL;
    } else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected a list of str or bytes, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_export_ext" "', argument " "3"" of type '" "gpgme_export_mode_t""'");
  } 
  arg3 = (gpgme_export_mode_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_export_ext(arg1,(char const *(*))arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    size_t i;
    free(vector2);
    for (i = 0; i < size2; i++)
    Py_XDECREF(pyVector2[i]);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    size_t i;
    free(vector2);
    for (i = 0; i < size2; i++)
    Py_XDECREF(pyVector2[i]);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_export_keys_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  gpgme_export_mode_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_export_keys_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_export_keys_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_export_keys_start" "', argument " "3"" of type '" "gpgme_export_mode_t""'");
  } 
  arg3 = (gpgme_export_mode_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_export_keys_start(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_export_keys(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  gpgme_export_mode_t arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_export_keys",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_export_keys" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_export_keys" "', argument " "3"" of type '" "gpgme_export_mode_t""'");
  } 
  arg3 = (gpgme_export_mode_t)(val3);
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_export_keys(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_primary_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_genkey_result_primary_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_primary_set" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_genkey_result_primary_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->primary = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_primary_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_genkey_result_primary_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_primary_get" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->primary);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_sub_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_genkey_result_sub_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_sub_set" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_genkey_result_sub_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->sub = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_sub_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_genkey_result_sub_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_sub_get" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->sub);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_uid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_genkey_result_uid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_uid_set" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_genkey_result_uid_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->uid = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_uid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_genkey_result_uid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_uid_get" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->uid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_genkey_result__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result__unused_set" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_genkey_result__unused_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_genkey_result__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result__unused_get" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_fpr_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_genkey_result_fpr_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_fpr_set" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_genkey_result_fpr_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->fpr) free((char*)arg1->fpr);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->fpr = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->fpr = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_fpr_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_genkey_result_fpr_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_fpr_get" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->fpr);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_pubkey_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_genkey_result_pubkey_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_pubkey_set" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | SWIG_POINTER_DISOWN )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->pubkey = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_pubkey_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_genkey_result_pubkey_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_pubkey_get" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_t) ((arg1)->pubkey);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_data, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_seckey_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_genkey_result_seckey_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_seckey_set" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | SWIG_POINTER_DISOWN )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->seckey = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_genkey_result_seckey_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_genkey_result_seckey_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_genkey_result_seckey_get" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_t) ((arg1)->seckey);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_data, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_genkey_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_genkey_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_genkey_result *)calloc(1, sizeof(struct _gpgme_op_genkey_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_genkey_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_genkey_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_genkey_result *arg1 = (struct _gpgme_op_genkey_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_genkey_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_genkey_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_genkey_result" "', argument " "1"" of type '" "struct _gpgme_op_genkey_result *""'"); 
  }
  arg1 = (struct _gpgme_op_genkey_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_genkey_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_genkey_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_genkey_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_genkey_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_genkey_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_genkey_start(arg1,(char const *)arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_genkey(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  gpgme_data_t arg3 = (gpgme_data_t) 0 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  gpgme_data_t wrapper3 = NULL ;
  PyObject *bytesio3 = NULL ;
  Py_buffer view3 ;
  int have_view3 = 0 ;
  gpgme_data_t wrapper4 = NULL ;
  PyObject *bytesio4 = NULL ;
  Py_buffer view4 ;
  int have_view4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_genkey",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_genkey" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    /* If we create a temporary wrapper3 object, we will store it in
         wrapperN, where N is 3.  Here in this fragment, SWIG will
         automatically append 3.  */
    memset(&view3, 0, sizeof view3);
    if (obj2 == Py_None)
    arg3 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj2, 3, &wrapper3,
        &bytesio3, &view3);
      if (pypointer == NULL)
      return NULL;
      have_view3 = !! view3.obj;
      
      /* input = obj2, 1 = arg3, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg3, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    /* If we create a temporary wrapper4 object, we will store it in
         wrapperN, where N is 4.  Here in this fragment, SWIG will
         automatically append 4.  */
    memset(&view4, 0, sizeof view4);
    if (obj3 == Py_None)
    arg4 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj3, 4, &wrapper4,
        &bytesio4, &view4);
      if (pypointer == NULL)
      return NULL;
      have_view4 = !! view4.obj;
      
      /* input = obj3, 1 = arg4, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg4, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_genkey(arg1,(char const *)arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper3 && view3.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper3->data.mem.buffer;
      new_size = wrapper3->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view3.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view3.len != new_size)
        {
          if (bytesio3 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view3);
            assert(view3.obj == NULL);
            retval = PyObject_CallMethod(bytesio3, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio3,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view3,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view3.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view3.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view3.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper3)
    gpgme_data_release(wrapper3);
    Py_XDECREF (bytesio3);
    if (have_view3 && view3.buf)
    PyBuffer_Release(&view3);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper4 && view4.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper4->data.mem.buffer;
      new_size = wrapper4->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view4.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view4.len != new_size)
        {
          if (bytesio4 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view4);
            assert(view4.obj == NULL);
            retval = PyObject_CallMethod(bytesio4, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio4,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view4,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view4.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view4.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view4.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper4)
    gpgme_data_release(wrapper4);
    Py_XDECREF (bytesio4);
    if (have_view4 && view4.buf)
    PyBuffer_Release(&view4);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_createkey_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned long arg4 ;
  unsigned long arg5 ;
  gpgme_key_t arg6 = (gpgme_key_t) 0 ;
  unsigned int arg7 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject *encodedInput3 = NULL ;
  unsigned long val4 ;
  int ecode4 = 0 ;
  unsigned long val5 ;
  int ecode5 = 0 ;
  void *argp6 = 0 ;
  int res6 = 0 ;
  unsigned int val7 ;
  int ecode7 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  PyObject * obj6 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOOOO:gpgme_op_createkey_start",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5,&obj6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_createkey_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_long(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_createkey_start" "', argument " "4"" of type '" "unsigned long""'");
  } 
  arg4 = (unsigned long)(val4);
  ecode5 = SWIG_AsVal_unsigned_SS_long(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_op_createkey_start" "', argument " "5"" of type '" "unsigned long""'");
  } 
  arg5 = (unsigned long)(val5);
  res6 = SWIG_ConvertPtr(obj5, &argp6,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res6)) {
    SWIG_exception_fail(SWIG_ArgError(res6), "in method '" "gpgme_op_createkey_start" "', argument " "6"" of type '" "gpgme_key_t""'"); 
  }
  arg6 = (gpgme_key_t)(argp6);
  ecode7 = SWIG_AsVal_unsigned_SS_int(obj6, &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "gpgme_op_createkey_start" "', argument " "7"" of type '" "unsigned int""'");
  } 
  arg7 = (unsigned int)(val7);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_createkey_start(arg1,(char const *)arg2,(char const *)arg3,arg4,arg5,arg6,arg7);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_createkey(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned long arg4 ;
  unsigned long arg5 ;
  gpgme_key_t arg6 = (gpgme_key_t) 0 ;
  unsigned int arg7 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject *encodedInput3 = NULL ;
  unsigned long val4 ;
  int ecode4 = 0 ;
  unsigned long val5 ;
  int ecode5 = 0 ;
  void *argp6 = 0 ;
  int res6 = 0 ;
  unsigned int val7 ;
  int ecode7 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  PyObject * obj6 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOOOO:gpgme_op_createkey",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5,&obj6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_createkey" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_long(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_createkey" "', argument " "4"" of type '" "unsigned long""'");
  } 
  arg4 = (unsigned long)(val4);
  ecode5 = SWIG_AsVal_unsigned_SS_long(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_op_createkey" "', argument " "5"" of type '" "unsigned long""'");
  } 
  arg5 = (unsigned long)(val5);
  res6 = SWIG_ConvertPtr(obj5, &argp6,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res6)) {
    SWIG_exception_fail(SWIG_ArgError(res6), "in method '" "gpgme_op_createkey" "', argument " "6"" of type '" "gpgme_key_t""'"); 
  }
  arg6 = (gpgme_key_t)(argp6);
  ecode7 = SWIG_AsVal_unsigned_SS_int(obj6, &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "gpgme_op_createkey" "', argument " "7"" of type '" "unsigned int""'");
  } 
  arg7 = (unsigned int)(val7);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_createkey(arg1,(char const *)arg2,(char const *)arg3,arg4,arg5,arg6,arg7);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_createsubkey_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned long arg4 ;
  unsigned long arg5 ;
  unsigned int arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned long val4 ;
  int ecode4 = 0 ;
  unsigned long val5 ;
  int ecode5 = 0 ;
  unsigned int val6 ;
  int ecode6 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOOO:gpgme_op_createsubkey_start",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_createsubkey_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_createsubkey_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_long(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_createsubkey_start" "', argument " "4"" of type '" "unsigned long""'");
  } 
  arg4 = (unsigned long)(val4);
  ecode5 = SWIG_AsVal_unsigned_SS_long(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_op_createsubkey_start" "', argument " "5"" of type '" "unsigned long""'");
  } 
  arg5 = (unsigned long)(val5);
  ecode6 = SWIG_AsVal_unsigned_SS_int(obj5, &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "gpgme_op_createsubkey_start" "', argument " "6"" of type '" "unsigned int""'");
  } 
  arg6 = (unsigned int)(val6);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_createsubkey_start(arg1,arg2,(char const *)arg3,arg4,arg5,arg6);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_createsubkey(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned long arg4 ;
  unsigned long arg5 ;
  unsigned int arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned long val4 ;
  int ecode4 = 0 ;
  unsigned long val5 ;
  int ecode5 = 0 ;
  unsigned int val6 ;
  int ecode6 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOOO:gpgme_op_createsubkey",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_createsubkey" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_createsubkey" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_long(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_createsubkey" "', argument " "4"" of type '" "unsigned long""'");
  } 
  arg4 = (unsigned long)(val4);
  ecode5 = SWIG_AsVal_unsigned_SS_long(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_op_createsubkey" "', argument " "5"" of type '" "unsigned long""'");
  } 
  arg5 = (unsigned long)(val5);
  ecode6 = SWIG_AsVal_unsigned_SS_int(obj5, &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "gpgme_op_createsubkey" "', argument " "6"" of type '" "unsigned int""'");
  } 
  arg6 = (unsigned int)(val6);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_createsubkey(arg1,arg2,(char const *)arg3,arg4,arg5,arg6);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_adduid_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_adduid_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_adduid_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_adduid_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_adduid_start" "', argument " "4"" of type '" "unsigned int""'");
  } 
  arg4 = (unsigned int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_adduid_start(arg1,arg2,(char const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_adduid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_adduid",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_adduid" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_adduid" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_adduid" "', argument " "4"" of type '" "unsigned int""'");
  } 
  arg4 = (unsigned int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_adduid(arg1,arg2,(char const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_revuid_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_revuid_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_revuid_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_revuid_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_revuid_start" "', argument " "4"" of type '" "unsigned int""'");
  } 
  arg4 = (unsigned int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_revuid_start(arg1,arg2,(char const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_revuid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_revuid",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_revuid" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_revuid" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_revuid" "', argument " "4"" of type '" "unsigned int""'");
  } 
  arg4 = (unsigned int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_revuid(arg1,arg2,(char const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_set_uid_flag_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  char *arg4 = (char *) 0 ;
  char *arg5 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  PyObject *encodedInput4 = NULL ;
  PyObject *encodedInput5 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_set_uid_flag_start",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_set_uid_flag_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_set_uid_flag_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj3 == Py_None)
    arg4 = NULL;
    else if (PyUnicode_Check(obj3))
    {
      encodedInput4 = PyUnicode_AsUTF8String(obj3);
      if (encodedInput4 == NULL)
      return NULL;
      arg4 = PyBytes_AsString(encodedInput4);
    }
    else if (PyBytes_Check(obj3))
    arg4 = PyBytes_AsString(obj3);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        4, obj3->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj4 == Py_None)
    arg5 = NULL;
    else if (PyUnicode_Check(obj4))
    {
      encodedInput5 = PyUnicode_AsUTF8String(obj4);
      if (encodedInput5 == NULL)
      return NULL;
      arg5 = PyBytes_AsString(encodedInput5);
    }
    else if (PyBytes_Check(obj4))
    arg5 = PyBytes_AsString(obj4);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        5, obj4->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_set_uid_flag_start(arg1,arg2,(char const *)arg3,(char const *)arg4,(char const *)arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    Py_XDECREF(encodedInput4);
  }
  {
    Py_XDECREF(encodedInput5);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  {
    Py_XDECREF(encodedInput4);
  }
  {
    Py_XDECREF(encodedInput5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_set_uid_flag(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  char *arg4 = (char *) 0 ;
  char *arg5 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  PyObject *encodedInput4 = NULL ;
  PyObject *encodedInput5 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_set_uid_flag",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_set_uid_flag" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_set_uid_flag" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj3 == Py_None)
    arg4 = NULL;
    else if (PyUnicode_Check(obj3))
    {
      encodedInput4 = PyUnicode_AsUTF8String(obj3);
      if (encodedInput4 == NULL)
      return NULL;
      arg4 = PyBytes_AsString(encodedInput4);
    }
    else if (PyBytes_Check(obj3))
    arg4 = PyBytes_AsString(obj3);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        4, obj3->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj4 == Py_None)
    arg5 = NULL;
    else if (PyUnicode_Check(obj4))
    {
      encodedInput5 = PyUnicode_AsUTF8String(obj4);
      if (encodedInput5 == NULL)
      return NULL;
      arg5 = PyBytes_AsString(encodedInput5);
    }
    else if (PyBytes_Check(obj4))
    arg5 = PyBytes_AsString(obj4);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        5, obj4->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_set_uid_flag(arg1,arg2,(char const *)arg3,(char const *)arg4,(char const *)arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  {
    Py_XDECREF(encodedInput4);
  }
  {
    Py_XDECREF(encodedInput5);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  {
    Py_XDECREF(encodedInput4);
  }
  {
    Py_XDECREF(encodedInput5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_genkey_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_genkey_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_genkey_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_genkey_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_genkey_result_t)gpgme_op_genkey_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    PyObject *fragile;
    fragile = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_genkey_result,
      0 );
    resultobj = _gpg_wrap_result(fragile, "GenkeyResult");
    Py_DECREF(fragile);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_delete_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) (gpgme_key_t)0 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_delete_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_delete_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_delete_start" "', argument " "2"" of type '" "gpgme_key_t const""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_delete_start" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_delete_start(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_delete(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) (gpgme_key_t)0 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_delete",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_delete" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_delete" "', argument " "2"" of type '" "gpgme_key_t const""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_delete" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_delete(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_delete_ext_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) (gpgme_key_t)0 ;
  unsigned int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_delete_ext_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_delete_ext_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_delete_ext_start" "', argument " "2"" of type '" "gpgme_key_t const""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_delete_ext_start" "', argument " "3"" of type '" "unsigned int""'");
  } 
  arg3 = (unsigned int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_delete_ext_start(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_delete_ext(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) (gpgme_key_t)0 ;
  unsigned int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_delete_ext",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_delete_ext" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_delete_ext" "', argument " "2"" of type '" "gpgme_key_t const""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_delete_ext" "', argument " "3"" of type '" "unsigned int""'");
  } 
  arg3 = (unsigned int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_delete_ext(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_keysign_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned long arg4 ;
  unsigned int arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned long val4 ;
  int ecode4 = 0 ;
  unsigned int val5 ;
  int ecode5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_keysign_start",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_keysign_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_keysign_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_long(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_keysign_start" "', argument " "4"" of type '" "unsigned long""'");
  } 
  arg4 = (unsigned long)(val4);
  ecode5 = SWIG_AsVal_unsigned_SS_int(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_op_keysign_start" "', argument " "5"" of type '" "unsigned int""'");
  } 
  arg5 = (unsigned int)(val5);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_keysign_start(arg1,arg2,(char const *)arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_keysign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned long arg4 ;
  unsigned int arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned long val4 ;
  int ecode4 = 0 ;
  unsigned int val5 ;
  int ecode5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_keysign",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_keysign" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_keysign" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_long(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_keysign" "', argument " "4"" of type '" "unsigned long""'");
  } 
  arg4 = (unsigned long)(val4);
  ecode5 = SWIG_AsVal_unsigned_SS_int(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_op_keysign" "', argument " "5"" of type '" "unsigned int""'");
  } 
  arg5 = (unsigned int)(val5);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_keysign(arg1,arg2,(char const *)arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_interact_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  unsigned int arg3 ;
  gpgme_interact_cb_t arg4 = (gpgme_interact_cb_t) 0 ;
  void *arg5 = (void *) 0 ;
  gpgme_data_t arg6 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper6 = NULL ;
  PyObject *bytesio6 = NULL ;
  Py_buffer view6 ;
  int have_view6 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_interact_start",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_interact_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_interact_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_interact_start" "', argument " "3"" of type '" "unsigned int""'");
  } 
  arg3 = (unsigned int)(val3);
  {
    if (! PyTuple_Check(obj3))
    return PyErr_Format(PyExc_TypeError, "interact callback must be a tuple");
    if (PyTuple_Size(obj3) != 2 && PyTuple_Size(obj3) != 3)
    return PyErr_Format(PyExc_TypeError,
      "interact callback must be a tuple of size 2 or 3");
    
    arg4 = (gpgme_interact_cb_t) _gpg_interact_cb;
    arg5 = obj3;
  }
  {
    /* If we create a temporary wrapper6 object, we will store it in
         wrapperN, where N is 6.  Here in this fragment, SWIG will
         automatically append 6.  */
    memset(&view6, 0, sizeof view6);
    if (obj4 == Py_None)
    arg6 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 6, &wrapper6,
        &bytesio6, &view6);
      if (pypointer == NULL)
      return NULL;
      have_view6 = !! view6.obj;
      
      /* input = obj4, 1 = arg6, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg6, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_interact_start(arg1,arg2,arg3,arg4,arg5,arg6);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_interact(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  unsigned int arg3 ;
  gpgme_interact_cb_t arg4 = (gpgme_interact_cb_t) 0 ;
  void *arg5 = (void *) 0 ;
  gpgme_data_t arg6 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  gpgme_data_t wrapper6 = NULL ;
  PyObject *bytesio6 = NULL ;
  Py_buffer view6 ;
  int have_view6 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_interact",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_interact" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_interact" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_interact" "', argument " "3"" of type '" "unsigned int""'");
  } 
  arg3 = (unsigned int)(val3);
  {
    if (! PyTuple_Check(obj3))
    return PyErr_Format(PyExc_TypeError, "interact callback must be a tuple");
    if (PyTuple_Size(obj3) != 2 && PyTuple_Size(obj3) != 3)
    return PyErr_Format(PyExc_TypeError,
      "interact callback must be a tuple of size 2 or 3");
    
    arg4 = (gpgme_interact_cb_t) _gpg_interact_cb;
    arg5 = obj3;
  }
  {
    /* If we create a temporary wrapper6 object, we will store it in
         wrapperN, where N is 6.  Here in this fragment, SWIG will
         automatically append 6.  */
    memset(&view6, 0, sizeof view6);
    if (obj4 == Py_None)
    arg6 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 6, &wrapper6,
        &bytesio6, &view6);
      if (pypointer == NULL)
      return NULL;
      have_view6 = !! view6.obj;
      
      /* input = obj4, 1 = arg6, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg6, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_interact(arg1,arg2,arg3,arg4,arg5,arg6);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper6 && view6.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper6->data.mem.buffer;
      new_size = wrapper6->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view6.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view6.len != new_size)
        {
          if (bytesio6 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view6);
            assert(view6.obj == NULL);
            retval = PyObject_CallMethod(bytesio6, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio6,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view6,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view6.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view6.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view6.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper6)
    gpgme_data_release(wrapper6);
    Py_XDECREF (bytesio6);
    if (have_view6 && view6.buf)
    PyBuffer_Release(&view6);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_tofu_policy_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  gpgme_tofu_policy_t arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_tofu_policy_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_tofu_policy_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_tofu_policy_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_tofu_policy_start" "', argument " "3"" of type '" "gpgme_tofu_policy_t""'");
  } 
  arg3 = (gpgme_tofu_policy_t)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_tofu_policy_start(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_tofu_policy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  gpgme_tofu_policy_t arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_tofu_policy",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_tofu_policy" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_tofu_policy" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_tofu_policy" "', argument " "3"" of type '" "gpgme_tofu_policy_t""'");
  } 
  arg3 = (gpgme_tofu_policy_t)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_tofu_policy(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_keylist_result_truncated_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_keylist_result *arg1 = (struct _gpgme_op_keylist_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_keylist_result_truncated_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_keylist_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_keylist_result_truncated_set" "', argument " "1"" of type '" "struct _gpgme_op_keylist_result *""'"); 
  }
  arg1 = (struct _gpgme_op_keylist_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_keylist_result_truncated_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->truncated = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_keylist_result_truncated_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_keylist_result *arg1 = (struct _gpgme_op_keylist_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_keylist_result_truncated_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_keylist_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_keylist_result_truncated_get" "', argument " "1"" of type '" "struct _gpgme_op_keylist_result *""'"); 
  }
  arg1 = (struct _gpgme_op_keylist_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->truncated);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_keylist_result__unused_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_keylist_result *arg1 = (struct _gpgme_op_keylist_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_keylist_result__unused_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_keylist_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_keylist_result__unused_set" "', argument " "1"" of type '" "struct _gpgme_op_keylist_result *""'"); 
  }
  arg1 = (struct _gpgme_op_keylist_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_keylist_result__unused_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_unused = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_keylist_result__unused_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_keylist_result *arg1 = (struct _gpgme_op_keylist_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_keylist_result__unused_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_keylist_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_keylist_result__unused_get" "', argument " "1"" of type '" "struct _gpgme_op_keylist_result *""'"); 
  }
  arg1 = (struct _gpgme_op_keylist_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_unused);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_keylist_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_keylist_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_keylist_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_keylist_result *)calloc(1, sizeof(struct _gpgme_op_keylist_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_keylist_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_keylist_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_keylist_result *arg1 = (struct _gpgme_op_keylist_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_keylist_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_keylist_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_keylist_result" "', argument " "1"" of type '" "struct _gpgme_op_keylist_result *""'"); 
  }
  arg1 = (struct _gpgme_op_keylist_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_keylist_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_keylist_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_keylist_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_keylist_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_keylist_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_keylist_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_keylist_result_t)gpgme_op_keylist_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    PyObject *fragile;
    fragile = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_keylist_result,
      0 );
    resultobj = _gpg_wrap_result(fragile, "KeylistResult");
    Py_DECREF(fragile);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_keylist_ext_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char **arg2 ;
  int arg3 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *vector2 = NULL ;
  size_t size2 ;
  PyObject **pyVector2 = NULL ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_keylist_ext_start",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_keylist_ext_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* Check if is a list */
    if (PyList_Check(obj1)) {
      size_t i, j;
      size2 = PyList_Size(obj1);
      arg2 = (char **) (vector2 = malloc((size2+1) * sizeof(char *)));
      pyVector2 = calloc(sizeof *pyVector2, size2);
      
      for (i = 0; i < size2; i++) {
        PyObject *o = PyList_GetItem(obj1,i);
        if (PyUnicode_Check(o))
        {
          pyVector2[i] = PyUnicode_AsUTF8String(o);
          if (pyVector2[i] == NULL)
          {
            free(vector2);
            for (j = 0; j < i; j++)
            Py_XDECREF(pyVector2[j]);
            return NULL;
          }
          arg2[i] = PyBytes_AsString(pyVector2[i]);
        }
        else if (PyString_Check(o))
        arg2[i] = PyString_AsString(o);
        else {
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only str or bytes, got %s "
            "at position %d",
            2, o->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
      }
      arg2[i] = NULL;
    } else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected a list of str or bytes, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_keylist_ext_start" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_keylist_ext_start" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_keylist_ext_start(arg1,(char const *(*))arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    size_t i;
    free(vector2);
    for (i = 0; i < size2; i++)
    Py_XDECREF(pyVector2[i]);
  }
  return resultobj;
fail:
  {
    size_t i;
    free(vector2);
    for (i = 0; i < size2; i++)
    Py_XDECREF(pyVector2[i]);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_keylist_from_data_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_keylist_from_data_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_keylist_from_data_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_keylist_from_data_start" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_keylist_from_data_start(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_keylist_next(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 = (gpgme_key_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_op_keylist_next",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_keylist_next" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_keylist_next" "', argument " "2"" of type '" "gpgme_key_t *""'"); 
  }
  arg2 = (gpgme_key_t *)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_keylist_next(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_keylist_end(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_keylist_end",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_keylist_end" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_keylist_end(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_passwd_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  unsigned int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_passwd_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_passwd_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_passwd_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_passwd_start" "', argument " "3"" of type '" "unsigned int""'");
  } 
  arg3 = (unsigned int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_passwd_start(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_passwd(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  unsigned int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_passwd",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_passwd" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_passwd" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_passwd" "', argument " "3"" of type '" "unsigned int""'");
  } 
  arg3 = (unsigned int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_passwd(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item__refs_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item__refs_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item__refs_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_trust_item__refs_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_refs = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item__refs_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item__refs_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item__refs_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_refs);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_keyid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item_keyid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_keyid_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_trust_item_keyid_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->keyid) free((char*)arg1->keyid);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->keyid = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->keyid = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_keyid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item_keyid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_keyid_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->keyid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item__keyid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[16+1] ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item__keyid_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item__keyid_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  res2 = SWIG_AsCharArray(obj1, temp2, 16+1);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_trust_item__keyid_set" "', argument " "2"" of type '" "char [16+1]""'");
  }
  arg2 = (char *)(temp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg2) memcpy(arg1->_keyid,arg2,16+1*sizeof(char));
    else memset(arg1->_keyid,0,16+1*sizeof(char));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item__keyid_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item__keyid_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item__keyid_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)(char *) ((arg1)->_keyid);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    size_t size = SWIG_strnlen(result, 16+1);
    
    
    
    resultobj = SWIG_FromCharPtrAndSize(result, size);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_type_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item_type_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_type_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_trust_item_type_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->type = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_type_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item_type_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_type_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->type);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_level_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item_level_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_level_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_trust_item_level_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->level = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_level_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item_level_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_level_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->level);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_owner_trust_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item_owner_trust_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_owner_trust_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_trust_item_owner_trust_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->owner_trust) free((char*)arg1->owner_trust);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->owner_trust = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->owner_trust = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_owner_trust_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item_owner_trust_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_owner_trust_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->owner_trust);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item__owner_trust_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[2] ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item__owner_trust_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item__owner_trust_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  res2 = SWIG_AsCharArray(obj1, temp2, 2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_trust_item__owner_trust_set" "', argument " "2"" of type '" "char [2]""'");
  }
  arg2 = (char *)(temp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg2) memcpy(arg1->_owner_trust,arg2,2*sizeof(char));
    else memset(arg1->_owner_trust,0,2*sizeof(char));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item__owner_trust_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item__owner_trust_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item__owner_trust_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)(char *) ((arg1)->_owner_trust);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    size_t size = SWIG_strnlen(result, 2);
    
    
    
    resultobj = SWIG_FromCharPtrAndSize(result, size);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_validity_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item_validity_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_validity_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_trust_item_validity_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->validity) free((char*)arg1->validity);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->validity = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->validity = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_validity_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item_validity_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_validity_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->validity);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item__validity_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char temp2[2] ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item__validity_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item__validity_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  res2 = SWIG_AsCharArray(obj1, temp2, 2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_trust_item__validity_set" "', argument " "2"" of type '" "char [2]""'");
  }
  arg2 = (char *)(temp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg2) memcpy(arg1->_validity,arg2,2*sizeof(char));
    else memset(arg1->_validity,0,2*sizeof(char));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item__validity_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item__validity_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item__validity_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)(char *) ((arg1)->_validity);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    size_t size = SWIG_strnlen(result, 2);
    
    
    
    resultobj = SWIG_FromCharPtrAndSize(result, size);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_trust_item_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_name_set" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_trust_item_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->name) free((char*)arg1->name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_trust_item_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_trust_item_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_trust_item_name_get" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_trust_item(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_trust_item")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_trust_item *)calloc(1, sizeof(struct _gpgme_trust_item));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_trust_item, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_trust_item(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_trust_item *arg1 = (struct _gpgme_trust_item *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_trust_item",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_trust_item" "', argument " "1"" of type '" "struct _gpgme_trust_item *""'"); 
  }
  arg1 = (struct _gpgme_trust_item *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_trust_item_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_trust_item, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_trustlist_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_trustlist_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_trustlist_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_trustlist_start" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_trustlist_start(arg1,(char const *)arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_trustlist_next(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_trust_item_t *arg2 = (gpgme_trust_item_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_op_trustlist_next",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_trustlist_next" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_trustlist_next" "', argument " "2"" of type '" "gpgme_trust_item_t *""'"); 
  }
  arg2 = (gpgme_trust_item_t *)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_trustlist_next(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_trustlist_end(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_trustlist_end",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_trustlist_end" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_trustlist_end(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_trust_item_ref(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t arg1 = (gpgme_trust_item_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_trust_item_ref",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_trust_item_ref" "', argument " "1"" of type '" "gpgme_trust_item_t""'"); 
  }
  arg1 = (gpgme_trust_item_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_trust_item_ref(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_trust_item_unref(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t arg1 = (gpgme_trust_item_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_trust_item_unref",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_trust_item_unref" "', argument " "1"" of type '" "gpgme_trust_item_t""'"); 
  }
  arg1 = (gpgme_trust_item_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_trust_item_unref(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_getauditlog_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  unsigned int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_getauditlog_start",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_getauditlog_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_getauditlog_start" "', argument " "2"" of type '" "gpgme_data_t""'"); 
  }
  arg2 = (gpgme_data_t)(argp2);
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_getauditlog_start" "', argument " "3"" of type '" "unsigned int""'");
  } 
  arg3 = (unsigned int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_getauditlog_start(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_getauditlog(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  unsigned int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  unsigned int val3 ;
  int ecode3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_getauditlog",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_getauditlog" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_getauditlog" "', argument " "2"" of type '" "gpgme_data_t""'"); 
  }
  arg2 = (gpgme_data_t)(argp2);
  ecode3 = SWIG_AsVal_unsigned_SS_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_op_getauditlog" "', argument " "3"" of type '" "unsigned int""'");
  } 
  arg3 = (unsigned int)(val3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_getauditlog(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_spawn_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char **arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  gpgme_data_t arg6 = (gpgme_data_t) 0 ;
  unsigned int arg7 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  void *vector3 = NULL ;
  size_t size3 ;
  PyObject **pyVector3 = NULL ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  void *argp5 = 0 ;
  int res5 = 0 ;
  void *argp6 = 0 ;
  int res6 = 0 ;
  unsigned int val7 ;
  int ecode7 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  PyObject * obj6 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOOOO:gpgme_op_spawn_start",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5,&obj6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_spawn_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    /* Check if is a list */
    if (PyList_Check(obj2)) {
      size_t i, j;
      size3 = PyList_Size(obj2);
      arg3 = (char **) (vector3 = malloc((size3+1) * sizeof(char *)));
      pyVector3 = calloc(sizeof *pyVector3, size3);
      
      for (i = 0; i < size3; i++) {
        PyObject *o = PyList_GetItem(obj2,i);
        if (PyUnicode_Check(o))
        {
          pyVector3[i] = PyUnicode_AsUTF8String(o);
          if (pyVector3[i] == NULL)
          {
            free(vector3);
            for (j = 0; j < i; j++)
            Py_XDECREF(pyVector3[j]);
            return NULL;
          }
          arg3[i] = PyBytes_AsString(pyVector3[i]);
        }
        else if (PyString_Check(o))
        arg3[i] = PyString_AsString(o);
        else {
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only str or bytes, got %s "
            "at position %d",
            3, o->ob_type->tp_name, i);
          free(arg3);
          return NULL;
        }
      }
      arg3[i] = NULL;
    } else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected a list of str or bytes, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  res4 = SWIG_ConvertPtr(obj3, &argp4,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_op_spawn_start" "', argument " "4"" of type '" "gpgme_data_t""'"); 
  }
  arg4 = (gpgme_data_t)(argp4);
  res5 = SWIG_ConvertPtr(obj4, &argp5,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gpgme_op_spawn_start" "', argument " "5"" of type '" "gpgme_data_t""'"); 
  }
  arg5 = (gpgme_data_t)(argp5);
  res6 = SWIG_ConvertPtr(obj5, &argp6,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res6)) {
    SWIG_exception_fail(SWIG_ArgError(res6), "in method '" "gpgme_op_spawn_start" "', argument " "6"" of type '" "gpgme_data_t""'"); 
  }
  arg6 = (gpgme_data_t)(argp6);
  ecode7 = SWIG_AsVal_unsigned_SS_int(obj6, &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "gpgme_op_spawn_start" "', argument " "7"" of type '" "unsigned int""'");
  } 
  arg7 = (unsigned int)(val7);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_spawn_start(arg1,(char const *)arg2,(char const *(*))arg3,arg4,arg5,arg6,arg7);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    size_t i;
    free(vector3);
    for (i = 0; i < size3; i++)
    Py_XDECREF(pyVector3[i]);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    size_t i;
    free(vector3);
    for (i = 0; i < size3; i++)
    Py_XDECREF(pyVector3[i]);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_spawn(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char **arg3 ;
  gpgme_data_t arg4 = (gpgme_data_t) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  gpgme_data_t arg6 = (gpgme_data_t) 0 ;
  unsigned int arg7 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  void *vector3 = NULL ;
  size_t size3 ;
  PyObject **pyVector3 = NULL ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  void *argp5 = 0 ;
  int res5 = 0 ;
  void *argp6 = 0 ;
  int res6 = 0 ;
  unsigned int val7 ;
  int ecode7 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  PyObject * obj6 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOOOO:gpgme_op_spawn",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5,&obj6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_spawn" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    /* Check if is a list */
    if (PyList_Check(obj2)) {
      size_t i, j;
      size3 = PyList_Size(obj2);
      arg3 = (char **) (vector3 = malloc((size3+1) * sizeof(char *)));
      pyVector3 = calloc(sizeof *pyVector3, size3);
      
      for (i = 0; i < size3; i++) {
        PyObject *o = PyList_GetItem(obj2,i);
        if (PyUnicode_Check(o))
        {
          pyVector3[i] = PyUnicode_AsUTF8String(o);
          if (pyVector3[i] == NULL)
          {
            free(vector3);
            for (j = 0; j < i; j++)
            Py_XDECREF(pyVector3[j]);
            return NULL;
          }
          arg3[i] = PyBytes_AsString(pyVector3[i]);
        }
        else if (PyString_Check(o))
        arg3[i] = PyString_AsString(o);
        else {
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only str or bytes, got %s "
            "at position %d",
            3, o->ob_type->tp_name, i);
          free(arg3);
          return NULL;
        }
      }
      arg3[i] = NULL;
    } else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected a list of str or bytes, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  res4 = SWIG_ConvertPtr(obj3, &argp4,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_op_spawn" "', argument " "4"" of type '" "gpgme_data_t""'"); 
  }
  arg4 = (gpgme_data_t)(argp4);
  res5 = SWIG_ConvertPtr(obj4, &argp5,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gpgme_op_spawn" "', argument " "5"" of type '" "gpgme_data_t""'"); 
  }
  arg5 = (gpgme_data_t)(argp5);
  res6 = SWIG_ConvertPtr(obj5, &argp6,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res6)) {
    SWIG_exception_fail(SWIG_ArgError(res6), "in method '" "gpgme_op_spawn" "', argument " "6"" of type '" "gpgme_data_t""'"); 
  }
  arg6 = (gpgme_data_t)(argp6);
  ecode7 = SWIG_AsVal_unsigned_SS_int(obj6, &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "gpgme_op_spawn" "', argument " "7"" of type '" "unsigned int""'");
  } 
  arg7 = (unsigned int)(val7);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_spawn(arg1,(char const *)arg2,(char const *(*))arg3,arg4,arg5,arg6,arg7);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    size_t i;
    free(vector3);
    for (i = 0; i < size3; i++)
    Py_XDECREF(pyVector3[i]);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    size_t i;
    free(vector3);
    for (i = 0; i < size3; i++)
    Py_XDECREF(pyVector3[i]);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_assuan_transact_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  gpgme_assuan_data_cb_t arg3 = (gpgme_assuan_data_cb_t) 0 ;
  void *arg4 = (void *) 0 ;
  gpgme_assuan_inquire_cb_t arg5 = (gpgme_assuan_inquire_cb_t) 0 ;
  void *arg6 = (void *) 0 ;
  gpgme_assuan_status_cb_t arg7 = (gpgme_assuan_status_cb_t) 0 ;
  void *arg8 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_assuan_transact_start",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_assuan_transact_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = arg4 = NULL;
    else
    {
      if (! PyTuple_Check(obj2))
      return PyErr_Format(PyExc_TypeError, "callback must be a tuple");
      if (PyTuple_Size(obj2) != 2)
      return PyErr_Format(PyExc_TypeError,
        "callback must be a tuple of size 2");
      if (! PyCallable_Check(PyTuple_GetItem(obj2, 1)))
      return PyErr_Format(PyExc_TypeError, "second item must be callable");
      arg3 = _gpg_assuan_data_cb;
      arg4 = obj2;
    }
  }
  {
    if (obj3 == Py_None)
    arg5 = arg6 = NULL;
    else
    {
      if (! PyTuple_Check(obj3))
      return PyErr_Format(PyExc_TypeError, "callback must be a tuple");
      if (PyTuple_Size(obj3) != 2)
      return PyErr_Format(PyExc_TypeError,
        "callback must be a tuple of size 2");
      if (! PyCallable_Check(PyTuple_GetItem(obj3, 1)))
      return PyErr_Format(PyExc_TypeError, "second item must be callable");
      arg5 = _gpg_assuan_inquire_cb;
      arg6 = obj3;
    }
  }
  {
    if (obj4 == Py_None)
    arg7 = arg8 = NULL;
    else
    {
      if (! PyTuple_Check(obj4))
      return PyErr_Format(PyExc_TypeError, "callback must be a tuple");
      if (PyTuple_Size(obj4) != 2)
      return PyErr_Format(PyExc_TypeError,
        "callback must be a tuple of size 2");
      if (! PyCallable_Check(PyTuple_GetItem(obj4, 1)))
      return PyErr_Format(PyExc_TypeError, "second item must be callable");
      arg7 = _gpg_assuan_status_cb;
      arg8 = obj4;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_assuan_transact_start(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,arg7,arg8);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_assuan_transact_ext(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  gpgme_assuan_data_cb_t arg3 = (gpgme_assuan_data_cb_t) 0 ;
  void *arg4 = (void *) 0 ;
  gpgme_assuan_inquire_cb_t arg5 = (gpgme_assuan_inquire_cb_t) 0 ;
  void *arg6 = (void *) 0 ;
  gpgme_assuan_status_cb_t arg7 = (gpgme_assuan_status_cb_t) 0 ;
  void *arg8 = (void *) 0 ;
  gpgme_error_t *arg9 = (gpgme_error_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  void *argp9 = 0 ;
  int res9 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOOO:gpgme_op_assuan_transact_ext",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_assuan_transact_ext" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = arg4 = NULL;
    else
    {
      if (! PyTuple_Check(obj2))
      return PyErr_Format(PyExc_TypeError, "callback must be a tuple");
      if (PyTuple_Size(obj2) != 2)
      return PyErr_Format(PyExc_TypeError,
        "callback must be a tuple of size 2");
      if (! PyCallable_Check(PyTuple_GetItem(obj2, 1)))
      return PyErr_Format(PyExc_TypeError, "second item must be callable");
      arg3 = _gpg_assuan_data_cb;
      arg4 = obj2;
    }
  }
  {
    if (obj3 == Py_None)
    arg5 = arg6 = NULL;
    else
    {
      if (! PyTuple_Check(obj3))
      return PyErr_Format(PyExc_TypeError, "callback must be a tuple");
      if (PyTuple_Size(obj3) != 2)
      return PyErr_Format(PyExc_TypeError,
        "callback must be a tuple of size 2");
      if (! PyCallable_Check(PyTuple_GetItem(obj3, 1)))
      return PyErr_Format(PyExc_TypeError, "second item must be callable");
      arg5 = _gpg_assuan_inquire_cb;
      arg6 = obj3;
    }
  }
  {
    if (obj4 == Py_None)
    arg7 = arg8 = NULL;
    else
    {
      if (! PyTuple_Check(obj4))
      return PyErr_Format(PyExc_TypeError, "callback must be a tuple");
      if (PyTuple_Size(obj4) != 2)
      return PyErr_Format(PyExc_TypeError,
        "callback must be a tuple of size 2");
      if (! PyCallable_Check(PyTuple_GetItem(obj4, 1)))
      return PyErr_Format(PyExc_TypeError, "second item must be callable");
      arg7 = _gpg_assuan_status_cb;
      arg8 = obj4;
    }
  }
  res9 = SWIG_ConvertPtr(obj5, &argp9,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res9)) {
    SWIG_exception_fail(SWIG_ArgError(res9), "in method '" "gpgme_op_assuan_transact_ext" "', argument " "9"" of type '" "gpgme_error_t *""'"); 
  }
  arg9 = (gpgme_error_t *)(argp9);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_assuan_transact_ext(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_vfs_mount_result_mount_dir_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_vfs_mount_result *arg1 = (struct _gpgme_op_vfs_mount_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_vfs_mount_result_mount_dir_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_vfs_mount_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_vfs_mount_result_mount_dir_set" "', argument " "1"" of type '" "struct _gpgme_op_vfs_mount_result *""'"); 
  }
  arg1 = (struct _gpgme_op_vfs_mount_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_vfs_mount_result_mount_dir_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->mount_dir) free((char*)arg1->mount_dir);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->mount_dir = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->mount_dir = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_vfs_mount_result_mount_dir_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_vfs_mount_result *arg1 = (struct _gpgme_op_vfs_mount_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_vfs_mount_result_mount_dir_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_vfs_mount_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_vfs_mount_result_mount_dir_get" "', argument " "1"" of type '" "struct _gpgme_op_vfs_mount_result *""'"); 
  }
  arg1 = (struct _gpgme_op_vfs_mount_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->mount_dir);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_vfs_mount_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_vfs_mount_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_vfs_mount_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_vfs_mount_result *)calloc(1, sizeof(struct _gpgme_op_vfs_mount_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_vfs_mount_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_vfs_mount_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_vfs_mount_result *arg1 = (struct _gpgme_op_vfs_mount_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_vfs_mount_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_vfs_mount_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_vfs_mount_result" "', argument " "1"" of type '" "struct _gpgme_op_vfs_mount_result *""'"); 
  }
  arg1 = (struct _gpgme_op_vfs_mount_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_vfs_mount_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_vfs_mount_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_vfs_mount_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_vfs_mount_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_vfs_mount_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_vfs_mount_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_vfs_mount_result_t)gpgme_op_vfs_mount_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    PyObject *fragile;
    fragile = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_vfs_mount_result,
      0 );
    resultobj = _gpg_wrap_result(fragile, "VFSMountResult");
    Py_DECREF(fragile);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_vfs_mount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned int arg4 ;
  gpgme_error_t *arg5 = (gpgme_error_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject *encodedInput3 = NULL ;
  unsigned int val4 ;
  int ecode4 = 0 ;
  void *argp5 = 0 ;
  int res5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_vfs_mount",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_vfs_mount" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_vfs_mount" "', argument " "4"" of type '" "unsigned int""'");
  } 
  arg4 = (unsigned int)(val4);
  res5 = SWIG_ConvertPtr(obj4, &argp5,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gpgme_op_vfs_mount" "', argument " "5"" of type '" "gpgme_error_t *""'"); 
  }
  arg5 = (gpgme_error_t *)(argp5);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_vfs_mount(arg1,(char const *)arg2,(char const *)arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_vfs_create(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t *arg2 ;
  char *arg3 = (char *) 0 ;
  unsigned int arg4 ;
  gpgme_error_t *arg5 = (gpgme_error_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput3 = NULL ;
  unsigned int val4 ;
  int ecode4 = 0 ;
  void *argp5 = 0 ;
  int res5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  {
    arg2 = NULL;
  }
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_vfs_create",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_vfs_create" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    int i, numb = 0;
    if (!PySequence_Check(obj1)) {
      PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
        2);
      return NULL;
    }
    if((numb = PySequence_Length(obj1)) != 0) {
      arg2 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
      for(i=0; i<numb; i++) {
        PyObject *pypointer = PySequence_GetItem(obj1, i);
        
        /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_p__gpgme_key */
        /* &1_descriptor = SWIGTYPE_p_a___p__gpgme_key *1_descriptor = SWIGTYPE_p__gpgme_key */
        
        /* Following code is from swig's python.swg.  */
        if ((SWIG_ConvertPtr(pypointer,(void **) &arg2[i], SWIGTYPE_p__gpgme_key,SWIG_POINTER_EXCEPTION | 0 )) == -1) {
          Py_DECREF(pypointer);
          PyErr_Format(PyExc_TypeError,
            "arg %d: list must contain only gpgme_key_ts, got %s "
            "at position %d",
            2, pypointer->ob_type->tp_name, i);
          free(arg2);
          return NULL;
        }
        Py_DECREF(pypointer);
      }
      arg2[numb] = NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_vfs_create" "', argument " "4"" of type '" "unsigned int""'");
  } 
  arg4 = (unsigned int)(val4);
  res5 = SWIG_ConvertPtr(obj4, &argp5,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gpgme_op_vfs_create" "', argument " "5"" of type '" "gpgme_error_t *""'"); 
  }
  arg5 = (gpgme_error_t *)(argp5);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_vfs_create(arg1,arg2,(char const *)arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    if (arg2) free(arg2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_no_arg_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_arg *arg1 = (struct gpgme_conf_arg *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_arg_no_arg_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_no_arg_set" "', argument " "1"" of type '" "struct gpgme_conf_arg *""'"); 
  }
  arg1 = (struct gpgme_conf_arg *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_arg_no_arg_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->no_arg = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_no_arg_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_arg *arg1 = (struct gpgme_conf_arg *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_arg_no_arg_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_no_arg_get" "', argument " "1"" of type '" "struct gpgme_conf_arg *""'"); 
  }
  arg1 = (struct gpgme_conf_arg *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->no_arg);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_arg *arg1 = (struct gpgme_conf_arg *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_arg_value *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_arg_value_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_get" "', argument " "1"" of type '" "struct gpgme_conf_arg *""'"); 
  }
  arg1 = (struct gpgme_conf_arg *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_arg_value *)& ((arg1)->value);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_conf_arg(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_arg *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_conf_arg")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct gpgme_conf_arg *)calloc(1, sizeof(struct gpgme_conf_arg));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_conf_arg, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_conf_arg(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_arg *arg1 = (struct gpgme_conf_arg *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_conf_arg",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_conf_arg" "', argument " "1"" of type '" "struct gpgme_conf_arg *""'"); 
  }
  arg1 = (struct gpgme_conf_arg *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *gpgme_conf_arg_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_gpgme_conf_arg, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_count_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_arg_value_count_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_count_set" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_arg_value_count_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->count = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_count_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_arg_value_count_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_count_get" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->count);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_uint32_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_arg_value_uint32_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_uint32_set" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_arg_value_uint32_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->uint32 = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_uint32_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_arg_value_uint32_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_uint32_get" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->uint32);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_int32_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_arg_value_int32_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_int32_set" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_arg_value_int32_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->int32 = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_int32_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_arg_value_int32_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_int32_get" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->int32);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_string_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_arg_value_string_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_string_set" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_arg_value_string_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->string) free((char*)arg1->string);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->string = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->string = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_value_string_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_arg_value_string_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_value_string_get" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->string);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_conf_arg_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_conf_arg_value")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_arg_value *)calloc(1, sizeof(gpgme_conf_arg_value));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_conf_arg_value, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_conf_arg_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_value *arg1 = (gpgme_conf_arg_value *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_conf_arg_value",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg_value, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_conf_arg_value" "', argument " "1"" of type '" "gpgme_conf_arg_value *""'"); 
  }
  arg1 = (gpgme_conf_arg_value *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *gpgme_conf_arg_value_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_gpgme_conf_arg_value, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_conf_opt_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_name_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->name) free((char*)arg1->name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_name_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_flags_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_flags_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_flags_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_opt_flags_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->flags = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_flags_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_flags_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_flags_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->flags);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_level_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  gpgme_conf_level_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_level_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_level_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_opt_level_set" "', argument " "2"" of type '" "gpgme_conf_level_t""'");
  } 
  arg2 = (gpgme_conf_level_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->level = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_level_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_level_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_level_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_level_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_level_t) ((arg1)->level);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_description_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_description_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_description_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_description_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->description) free((char*)arg1->description);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->description = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->description = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_description_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_description_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_description_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->description);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_type_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  gpgme_conf_type_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_type_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_type_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_opt_type_set" "', argument " "2"" of type '" "gpgme_conf_type_t""'");
  } 
  arg2 = (gpgme_conf_type_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->type = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_type_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_type_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_type_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_type_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_type_t) ((arg1)->type);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_alt_type_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  gpgme_conf_type_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_alt_type_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_alt_type_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_opt_alt_type_set" "', argument " "2"" of type '" "gpgme_conf_type_t""'");
  } 
  arg2 = (gpgme_conf_type_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->alt_type = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_alt_type_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_type_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_alt_type_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_alt_type_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_type_t) ((arg1)->alt_type);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_argname_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_argname_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_argname_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_argname_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->argname) free((char*)arg1->argname);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->argname = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->argname = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_argname_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_argname_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_argname_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->argname);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_default_value_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  gpgme_conf_arg_t arg2 = (gpgme_conf_arg_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_default_value_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_default_value_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_conf_arg, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_default_value_set" "', argument " "2"" of type '" "gpgme_conf_arg_t""'"); 
  }
  arg2 = (gpgme_conf_arg_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->default_value = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_default_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_arg_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_default_value_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_default_value_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_arg_t) ((arg1)->default_value);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_conf_arg_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p_gpgme_conf_arg,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_default_description_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_default_description_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_default_description_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_default_description_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->default_description) free((char*)arg1->default_description);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->default_description = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->default_description = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_default_description_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_default_description_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_default_description_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->default_description);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_no_arg_value_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  gpgme_conf_arg_t arg2 = (gpgme_conf_arg_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_no_arg_value_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_no_arg_value_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_conf_arg, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_no_arg_value_set" "', argument " "2"" of type '" "gpgme_conf_arg_t""'"); 
  }
  arg2 = (gpgme_conf_arg_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->no_arg_value = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_no_arg_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_arg_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_no_arg_value_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_no_arg_value_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_arg_t) ((arg1)->no_arg_value);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_conf_arg_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p_gpgme_conf_arg,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_no_arg_description_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_no_arg_description_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_no_arg_description_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_no_arg_description_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->no_arg_description) free((char*)arg1->no_arg_description);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->no_arg_description = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->no_arg_description = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_no_arg_description_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_no_arg_description_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_no_arg_description_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->no_arg_description);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_value_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  gpgme_conf_arg_t arg2 = (gpgme_conf_arg_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_value_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_value_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_conf_arg, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_value_set" "', argument " "2"" of type '" "gpgme_conf_arg_t""'"); 
  }
  arg2 = (gpgme_conf_arg_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->value = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_arg_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_value_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_value_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_arg_t) ((arg1)->value);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_conf_arg_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p_gpgme_conf_arg,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_change_value_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_change_value_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_change_value_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_opt_change_value_set" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->change_value = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_change_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_change_value_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_change_value_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int) ((arg1)->change_value);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_new_value_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  gpgme_conf_arg_t arg2 = (gpgme_conf_arg_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_new_value_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_new_value_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_conf_arg, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_new_value_set" "', argument " "2"" of type '" "gpgme_conf_arg_t""'"); 
  }
  arg2 = (gpgme_conf_arg_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->new_value = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_new_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_arg_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_new_value_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_new_value_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_arg_t) ((arg1)->new_value);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_conf_arg_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *o = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p_gpgme_conf_arg,  0 );
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_user_data_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *arg2 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_opt_user_data_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_user_data_set" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  res2 = SWIG_ConvertPtr(obj1,SWIG_as_voidptrptr(&arg2), 0, SWIG_POINTER_DISOWN);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_opt_user_data_set" "', argument " "2"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->user_data = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_user_data_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  void *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_opt_user_data_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_user_data_get" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (void *) ((arg1)->user_data);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_conf_opt(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_conf_opt")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct gpgme_conf_opt *)calloc(1, sizeof(struct gpgme_conf_opt));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_conf_opt, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_conf_opt(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_opt *arg1 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_conf_opt",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_conf_opt" "', argument " "1"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg1 = (struct gpgme_conf_opt *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *gpgme_conf_opt_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_gpgme_conf_opt, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_conf_comp__last_opt_p_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  gpgme_conf_opt_t *arg2 = (gpgme_conf_opt_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_comp__last_opt_p_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp__last_opt_p_set" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_comp__last_opt_p_set" "', argument " "2"" of type '" "gpgme_conf_opt_t *""'"); 
  }
  arg2 = (gpgme_conf_opt_t *)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_last_opt_p = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp__last_opt_p_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_conf_opt_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_comp__last_opt_p_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp__last_opt_p_get" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_conf_opt_t *) ((arg1)->_last_opt_p);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p_gpgme_conf_opt, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_comp_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp_name_set" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_comp_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->name) free((char*)arg1->name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_comp_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp_name_get" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp_description_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_comp_description_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp_description_set" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_comp_description_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->description) free((char*)arg1->description);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->description = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->description = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp_description_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_comp_description_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp_description_get" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->description);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp_program_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_comp_program_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp_program_name_set" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_comp_program_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->program_name) free((char*)arg1->program_name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->program_name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->program_name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp_program_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_comp_program_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp_program_name_get" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->program_name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp_options_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  struct gpgme_conf_opt *arg2 = (struct gpgme_conf_opt *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_comp_options_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp_options_set" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_conf_opt, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_conf_comp_options_set" "', argument " "2"" of type '" "struct gpgme_conf_opt *""'"); 
  }
  arg2 = (struct gpgme_conf_opt *)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->options = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_comp_options_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  struct gpgme_conf_opt *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_comp_options_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_comp_options_get" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct gpgme_conf_opt *) ((arg1)->options);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_conf_comp(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_conf_comp")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct gpgme_conf_comp *)calloc(1, sizeof(struct gpgme_conf_comp));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_conf_comp, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_conf_comp(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct gpgme_conf_comp *arg1 = (struct gpgme_conf_comp *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_conf_comp",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_conf_comp" "', argument " "1"" of type '" "struct gpgme_conf_comp *""'"); 
  }
  arg1 = (struct gpgme_conf_comp *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *gpgme_conf_comp_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_gpgme_conf_comp, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_conf_arg_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_t *arg1 = (gpgme_conf_arg_t *) 0 ;
  gpgme_conf_type_t arg2 ;
  void *arg3 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int res3 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_conf_arg_new",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_conf_arg, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_new" "', argument " "1"" of type '" "gpgme_conf_arg_t *""'"); 
  }
  arg1 = (gpgme_conf_arg_t *)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_arg_new" "', argument " "2"" of type '" "gpgme_conf_type_t""'");
  } 
  arg2 = (gpgme_conf_type_t)(val2);
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_conf_arg_new" "', argument " "3"" of type '" "void const *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_conf_arg_new(arg1,arg2,(void const *)arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_arg_release(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_arg_t arg1 = (gpgme_conf_arg_t) 0 ;
  gpgme_conf_type_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_conf_arg_release",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_arg, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_arg_release" "', argument " "1"" of type '" "gpgme_conf_arg_t""'"); 
  }
  arg1 = (gpgme_conf_arg_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_arg_release" "', argument " "2"" of type '" "gpgme_conf_type_t""'");
  } 
  arg2 = (gpgme_conf_type_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_conf_arg_release(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_opt_change(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_opt_t arg1 = (gpgme_conf_opt_t) 0 ;
  int arg2 ;
  gpgme_conf_arg_t arg3 = (gpgme_conf_arg_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_conf_opt_change",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_opt, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_opt_change" "', argument " "1"" of type '" "gpgme_conf_opt_t""'"); 
  }
  arg1 = (gpgme_conf_opt_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_conf_opt_change" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_gpgme_conf_arg, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_conf_opt_change" "', argument " "3"" of type '" "gpgme_conf_arg_t""'"); 
  }
  arg3 = (gpgme_conf_arg_t)(argp3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_conf_opt_change(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_conf_release(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_conf_comp_t arg1 = (gpgme_conf_comp_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_conf_release",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_conf_release" "', argument " "1"" of type '" "gpgme_conf_comp_t""'"); 
  }
  arg1 = (gpgme_conf_comp_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_conf_release(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_conf_load(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_conf_comp_t *arg2 = (gpgme_conf_comp_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_op_conf_load",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_conf_load" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_conf_load" "', argument " "2"" of type '" "gpgme_conf_comp_t *""'"); 
  }
  arg2 = (gpgme_conf_comp_t *)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_conf_load(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_conf_save(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_conf_comp_t arg2 = (gpgme_conf_comp_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_op_conf_save",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_conf_save" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_conf_comp, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_conf_save" "', argument " "2"" of type '" "gpgme_conf_comp_t""'"); 
  }
  arg2 = (gpgme_conf_comp_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_conf_save(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_conf_dir(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char **arg3 = (char **) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_conf_dir",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_conf_dir" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_p_char, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_op_conf_dir" "', argument " "3"" of type '" "char **""'"); 
  }
  arg3 = (char **)(argp3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_conf_dir(arg1,(char const *)arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_name_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_name_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_query_swdb_result_name_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->name) free((char*)arg1->name);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->name = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->name = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_name_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_name_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->name);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_iversion_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_iversion_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_iversion_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_query_swdb_result_iversion_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->iversion) free((char*)arg1->iversion);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->iversion = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->iversion = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_iversion_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_iversion_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_iversion_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->iversion);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_created_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_created_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_created_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_created_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->created = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_created_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_created_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_created_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->created);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_retrieved_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_retrieved_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_retrieved_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_retrieved_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->retrieved = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_retrieved_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_retrieved_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_retrieved_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->retrieved);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_warning_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_warning_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_warning_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_warning_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->warning = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_warning_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_warning_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_warning_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->warning);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_update_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_update_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_update_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_update_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->update = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_update_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_update_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_update_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->update);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_urgent_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_urgent_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_urgent_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_urgent_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->urgent = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_urgent_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_urgent_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_urgent_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->urgent);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_noinfo_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_noinfo_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_noinfo_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_noinfo_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->noinfo = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_noinfo_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_noinfo_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_noinfo_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->noinfo);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_unknown_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_unknown_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_unknown_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_unknown_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->unknown = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_unknown_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_unknown_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_unknown_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->unknown);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_tooold_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_tooold_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_tooold_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_tooold_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->tooold = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_tooold_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_tooold_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_tooold_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->tooold);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_error_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_error_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_error_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_error_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->error = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_error_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_error_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_error_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->error);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result__reserved_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result__reserved_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result__reserved_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result__reserved_set" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->_reserved = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result__reserved_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned int result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result__reserved_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result__reserved_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned int) ((arg1)->_reserved);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_version_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_version_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_version_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(obj1, &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gpgme_op_query_swdb_result_version_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1->version) free((char*)arg1->version);
    if (arg2) {
      size_t size = strlen((const char *)(arg2)) + 1;
      arg1->version = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
    } else {
      arg1->version = 0;
    }
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_version_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_version_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_version_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *) ((arg1)->version);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_reldate_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  unsigned long arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned long val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_query_swdb_result_reldate_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_reldate_set" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_long(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gpgme_op_query_swdb_result_reldate_set" "', argument " "2"" of type '" "unsigned long""'");
  } 
  arg2 = (unsigned long)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->reldate = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_query_swdb_result_reldate_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_query_swdb_result_reldate_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_query_swdb_result_reldate_get" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long) ((arg1)->reldate);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_query_swdb_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_query_swdb_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_query_swdb_result *)calloc(1, sizeof(struct _gpgme_op_query_swdb_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_query_swdb_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_query_swdb_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_query_swdb_result *arg1 = (struct _gpgme_op_query_swdb_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_query_swdb_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_query_swdb_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_query_swdb_result" "', argument " "1"" of type '" "struct _gpgme_op_query_swdb_result *""'"); 
  }
  arg1 = (struct _gpgme_op_query_swdb_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_query_swdb_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_query_swdb_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_query_swdb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  unsigned int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject *encodedInput3 = NULL ;
  unsigned int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_op_query_swdb",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_query_swdb" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_unsigned_SS_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_op_query_swdb" "', argument " "4"" of type '" "unsigned int""'");
  } 
  arg4 = (unsigned int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_query_swdb(arg1,(char const *)arg2,(char const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_query_swdb_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_query_swdb_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_query_swdb_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_query_swdb_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_query_swdb_result_t)gpgme_op_query_swdb_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_query_swdb_result, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_global_flag(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  char *arg2 = (char *) 0 ;
  PyObject *encodedInput1 = NULL ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_set_global_flag",&obj0,&obj1)) SWIG_fail;
  {
    if (obj0 == Py_None)
    arg1 = NULL;
    else if (PyUnicode_Check(obj0))
    {
      encodedInput1 = PyUnicode_AsUTF8String(obj0);
      if (encodedInput1 == NULL)
      return NULL;
      arg1 = PyBytes_AsString(encodedInput1);
    }
    else if (PyBytes_Check(obj0))
    arg1 = PyBytes_AsString(obj0);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        1, obj0->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_set_global_flag((char const *)arg1,(char const *)arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  {
    Py_XDECREF(encodedInput1);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput1);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_check_version(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  PyObject *encodedInput1 = NULL ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_check_version",&obj0)) SWIG_fail;
  {
    if (obj0 == Py_None)
    arg1 = NULL;
    else if (PyUnicode_Check(obj0))
    {
      encodedInput1 = PyUnicode_AsUTF8String(obj0);
      if (encodedInput1 == NULL)
      return NULL;
      arg1 = PyBytes_AsString(encodedInput1);
    }
    else if (PyBytes_Check(obj0))
    arg1 = PyBytes_AsString(obj0);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        1, obj0->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_check_version((char const *)arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    Py_XDECREF(encodedInput1);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_check_version_internal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  size_t arg2 ;
  PyObject *encodedInput1 = NULL ;
  size_t val2 ;
  int ecode2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_check_version_internal",&obj0,&obj1)) SWIG_fail;
  {
    if (obj0 == Py_None)
    arg1 = NULL;
    else if (PyUnicode_Check(obj0))
    {
      encodedInput1 = PyUnicode_AsUTF8String(obj0);
      if (encodedInput1 == NULL)
      return NULL;
      arg1 = PyBytes_AsString(encodedInput1);
    }
    else if (PyBytes_Check(obj0))
    arg1 = PyBytes_AsString(obj0);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        1, obj0->ob_type->tp_name);
      return NULL;
    }
  }
  ecode2 = SWIG_AsVal_size_t(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_check_version_internal" "', argument " "2"" of type '" "size_t""'");
  } 
  arg2 = (size_t)(val2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_check_version_internal((char const *)arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    Py_XDECREF(encodedInput1);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_dirinfo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  PyObject *encodedInput1 = NULL ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_dirinfo",&obj0)) SWIG_fail;
  {
    if (obj0 == Py_None)
    arg1 = NULL;
    else if (PyUnicode_Check(obj0))
    {
      encodedInput1 = PyUnicode_AsUTF8String(obj0);
      if (encodedInput1 == NULL)
      return NULL;
      arg1 = PyBytes_AsString(encodedInput1);
    }
    else if (PyBytes_Check(obj0))
    arg1 = PyBytes_AsString(obj0);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        1, obj0->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_get_dirinfo((char const *)arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    Py_XDECREF(encodedInput1);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_engine_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_engine_info_t *arg1 = (gpgme_engine_info_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_get_engine_info",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_engine_info" "', argument " "1"" of type '" "gpgme_engine_info_t *""'"); 
  }
  arg1 = (gpgme_engine_info_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_get_engine_info(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_set_engine_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_protocol_t arg1 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject *encodedInput3 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_set_engine_info",&obj0,&obj1,&obj2)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_set_engine_info" "', argument " "1"" of type '" "gpgme_protocol_t""'");
  } 
  arg1 = (gpgme_protocol_t)(val1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = NULL;
    else if (PyUnicode_Check(obj2))
    {
      encodedInput3 = PyUnicode_AsUTF8String(obj2);
      if (encodedInput3 == NULL)
      return NULL;
      arg3 = PyBytes_AsString(encodedInput3);
    }
    else if (PyBytes_Check(obj2))
    arg3 = PyBytes_AsString(obj2);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        3, obj2->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_set_engine_info(arg1,(char const *)arg2,(char const *)arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  {
    Py_XDECREF(encodedInput3);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_engine_check_version(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_protocol_t arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_engine_check_version",&obj0)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_engine_check_version" "', argument " "1"" of type '" "gpgme_protocol_t""'");
  } 
  arg1 = (gpgme_protocol_t)(val1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_engine_check_version(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_result_ref(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  void *arg1 = (void *) 0 ;
  int res1 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_result_ref",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0,SWIG_as_voidptrptr(&arg1), 0, 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_result_ref" "', argument " "1"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_result_ref(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_result_unref(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  void *arg1 = (void *) 0 ;
  int res1 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_result_unref",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0,SWIG_as_voidptrptr(&arg1), 0, 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_result_unref" "', argument " "1"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_result_unref(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_pubkey_algo_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_subkey_t arg1 = (gpgme_subkey_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_pubkey_algo_string",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_subkey, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_pubkey_algo_string" "', argument " "1"" of type '" "gpgme_subkey_t""'"); 
  }
  arg1 = (gpgme_subkey_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_pubkey_algo_string(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  gpgme_free(result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_pubkey_algo_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_pubkey_algo_t arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_pubkey_algo_name",&obj0)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_pubkey_algo_name" "', argument " "1"" of type '" "gpgme_pubkey_algo_t""'");
  } 
  arg1 = (gpgme_pubkey_algo_t)(val1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_pubkey_algo_name(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_hash_algo_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_hash_algo_t arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_hash_algo_name",&obj0)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gpgme_hash_algo_name" "', argument " "1"" of type '" "gpgme_hash_algo_t""'");
  } 
  arg1 = (gpgme_hash_algo_t)(val1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_hash_algo_name(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_addrspec_from_uid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  PyObject *encodedInput1 = NULL ;
  PyObject * obj0 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_addrspec_from_uid",&obj0)) SWIG_fail;
  {
    if (obj0 == Py_None)
    arg1 = NULL;
    else if (PyUnicode_Check(obj0))
    {
      encodedInput1 = PyUnicode_AsUTF8String(obj0);
      if (encodedInput1 == NULL)
      return NULL;
      arg1 = PyBytes_AsString(encodedInput1);
    }
    else if (PyBytes_Check(obj0))
    arg1 = PyBytes_AsString(obj0);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        1, obj0->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_addrspec_from_uid((char const *)arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    Py_XDECREF(encodedInput1);
  }
  gpgme_free(result);
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_edit_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  gpgme_edit_cb_t arg3 = (gpgme_edit_cb_t) 0 ;
  void *arg4 = (void *) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int res4 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_edit_start",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_edit_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_edit_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    int res = SWIG_ConvertFunctionPtr(obj2, (void**)(&arg3), SWIGTYPE_p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_op_edit_start" "', argument " "3"" of type '" "gpgme_edit_cb_t""'"); 
    }
  }
  res4 = SWIG_ConvertPtr(obj3,SWIG_as_voidptrptr(&arg4), 0, 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_op_edit_start" "', argument " "4"" of type '" "void *""'"); 
  }
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_edit_start(arg1,arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  gpgme_edit_cb_t arg3 = (gpgme_edit_cb_t) 0 ;
  void *arg4 = (void *) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int res4 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_edit",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_edit" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_edit" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    int res = SWIG_ConvertFunctionPtr(obj2, (void**)(&arg3), SWIGTYPE_p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_op_edit" "', argument " "3"" of type '" "gpgme_edit_cb_t""'"); 
    }
  }
  res4 = SWIG_ConvertPtr(obj3,SWIG_as_voidptrptr(&arg4), 0, 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_op_edit" "', argument " "4"" of type '" "void *""'"); 
  }
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_edit(arg1,arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_card_edit_start(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  gpgme_edit_cb_t arg3 = (gpgme_edit_cb_t) 0 ;
  void *arg4 = (void *) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int res4 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_card_edit_start",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_card_edit_start" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_card_edit_start" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    int res = SWIG_ConvertFunctionPtr(obj2, (void**)(&arg3), SWIGTYPE_p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_op_card_edit_start" "', argument " "3"" of type '" "gpgme_edit_cb_t""'"); 
    }
  }
  res4 = SWIG_ConvertPtr(obj3,SWIG_as_voidptrptr(&arg4), 0, 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_op_card_edit_start" "', argument " "4"" of type '" "void *""'"); 
  }
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_card_edit_start(arg1,arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_card_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  gpgme_edit_cb_t arg3 = (gpgme_edit_cb_t) 0 ;
  void *arg4 = (void *) 0 ;
  gpgme_data_t arg5 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int res4 ;
  gpgme_data_t wrapper5 = NULL ;
  PyObject *bytesio5 = NULL ;
  Py_buffer view5 ;
  int have_view5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_op_card_edit",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_card_edit" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_op_card_edit" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    int res = SWIG_ConvertFunctionPtr(obj2, (void**)(&arg3), SWIGTYPE_p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_op_card_edit" "', argument " "3"" of type '" "gpgme_edit_cb_t""'"); 
    }
  }
  res4 = SWIG_ConvertPtr(obj3,SWIG_as_voidptrptr(&arg4), 0, 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_op_card_edit" "', argument " "4"" of type '" "void *""'"); 
  }
  {
    /* If we create a temporary wrapper5 object, we will store it in
         wrapperN, where N is 5.  Here in this fragment, SWIG will
         automatically append 5.  */
    memset(&view5, 0, sizeof view5);
    if (obj4 == Py_None)
    arg5 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj4, 5, &wrapper5,
        &bytesio5, &view5);
      if (pypointer == NULL)
      return NULL;
      have_view5 = !! view5.obj;
      
      /* input = obj4, 1 = arg5, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg5, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_card_edit(arg1,arg2,arg3,arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper5 && view5.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper5->data.mem.buffer;
      new_size = wrapper5->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view5.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view5.len != new_size)
        {
          if (bytesio5 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view5);
            assert(view5.obj == NULL);
            retval = PyObject_CallMethod(bytesio5, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio5,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view5,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view5.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view5.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view5.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper5)
    gpgme_data_release(wrapper5);
    Py_XDECREF (bytesio5);
    if (have_view5 && view5.buf)
    PyBuffer_Release(&view5);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_sig_status(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  _gpgme_sig_stat_t *arg3 = (_gpgme_sig_stat_t *) 0 ;
  time_t *arg4 = (time_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_get_sig_status",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_sig_status" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_get_sig_status" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p__gpgme_sig_stat_t, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_get_sig_status" "', argument " "3"" of type '" "_gpgme_sig_stat_t *""'"); 
  }
  arg3 = (_gpgme_sig_stat_t *)(argp3);
  res4 = SWIG_ConvertPtr(obj3, &argp4,SWIGTYPE_p_time_t, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_get_sig_status" "', argument " "4"" of type '" "time_t *""'"); 
  }
  arg4 = (time_t *)(argp4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_get_sig_status(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_sig_ulong_attr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  _gpgme_attr_t arg3 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_get_sig_ulong_attr",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_sig_ulong_attr" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_get_sig_ulong_attr" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_get_sig_ulong_attr" "', argument " "3"" of type '" "_gpgme_attr_t""'");
  } 
  arg3 = (_gpgme_attr_t)(val3);
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_get_sig_ulong_attr" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long)gpgme_get_sig_ulong_attr(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_sig_string_attr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  _gpgme_attr_t arg3 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_get_sig_string_attr",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_sig_string_attr" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_get_sig_string_attr" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_get_sig_string_attr" "', argument " "3"" of type '" "_gpgme_attr_t""'");
  } 
  arg3 = (_gpgme_attr_t)(val3);
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_get_sig_string_attr" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_get_sig_string_attr(arg1,arg2,arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_get_sig_key(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  int arg2 ;
  gpgme_key_t *arg3 = (gpgme_key_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_get_sig_key",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_get_sig_key" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_get_sig_key" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_get_sig_key" "', argument " "3"" of type '" "gpgme_key_t *""'"); 
  }
  arg3 = (gpgme_key_t *)(argp3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_get_sig_key(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_new_with_read_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  int (*arg2)(void *,char *,size_t,size_t *) = (int (*)(void *,char *,size_t,size_t *)) 0 ;
  void *arg3 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_data_new_with_read_cb",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_new_with_read_cb" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(obj1, (void**)(&arg2), SWIGTYPE_p_f_p_void_p_char_size_t_p_size_t__int);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_data_new_with_read_cb" "', argument " "2"" of type '" "int (*)(void *,char *,size_t,size_t *)""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_data_new_with_read_cb" "', argument " "3"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_data_new_with_read_cb(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_get_string_attr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t arg1 = (gpgme_key_t) 0 ;
  _gpgme_attr_t arg2 ;
  void *arg3 = (void *) 0 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int res3 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_key_get_string_attr",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_get_string_attr" "', argument " "1"" of type '" "gpgme_key_t""'"); 
  }
  arg1 = (gpgme_key_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_key_get_string_attr" "', argument " "2"" of type '" "_gpgme_attr_t""'");
  } 
  arg2 = (_gpgme_attr_t)(val2);
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_key_get_string_attr" "', argument " "3"" of type '" "void const *""'"); 
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_key_get_string_attr" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_key_get_string_attr(arg1,arg2,(void const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_get_ulong_attr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t arg1 = (gpgme_key_t) 0 ;
  _gpgme_attr_t arg2 ;
  void *arg3 = (void *) 0 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int res3 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_key_get_ulong_attr",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_get_ulong_attr" "', argument " "1"" of type '" "gpgme_key_t""'"); 
  }
  arg1 = (gpgme_key_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_key_get_ulong_attr" "', argument " "2"" of type '" "_gpgme_attr_t""'");
  } 
  arg2 = (_gpgme_attr_t)(val2);
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_key_get_ulong_attr" "', argument " "3"" of type '" "void const *""'"); 
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_key_get_ulong_attr" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long)gpgme_key_get_ulong_attr(arg1,arg2,(void const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_sig_get_string_attr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t arg1 = (gpgme_key_t) 0 ;
  int arg2 ;
  _gpgme_attr_t arg3 ;
  void *arg4 = (void *) 0 ;
  int arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int res4 ;
  int val5 ;
  int ecode5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_key_sig_get_string_attr",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_sig_get_string_attr" "', argument " "1"" of type '" "gpgme_key_t""'"); 
  }
  arg1 = (gpgme_key_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_key_sig_get_string_attr" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_key_sig_get_string_attr" "', argument " "3"" of type '" "_gpgme_attr_t""'");
  } 
  arg3 = (_gpgme_attr_t)(val3);
  res4 = SWIG_ConvertPtr(obj3,SWIG_as_voidptrptr(&arg4), 0, 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_key_sig_get_string_attr" "', argument " "4"" of type '" "void const *""'"); 
  }
  ecode5 = SWIG_AsVal_int(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_key_sig_get_string_attr" "', argument " "5"" of type '" "int""'");
  } 
  arg5 = (int)(val5);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_key_sig_get_string_attr(arg1,arg2,arg3,(void const *)arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_sig_get_ulong_attr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t arg1 = (gpgme_key_t) 0 ;
  int arg2 ;
  _gpgme_attr_t arg3 ;
  void *arg4 = (void *) 0 ;
  int arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int res4 ;
  int val5 ;
  int ecode5 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  unsigned long result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOO:gpgme_key_sig_get_ulong_attr",&obj0,&obj1,&obj2,&obj3,&obj4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_sig_get_ulong_attr" "', argument " "1"" of type '" "gpgme_key_t""'"); 
  }
  arg1 = (gpgme_key_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_key_sig_get_ulong_attr" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  ecode3 = SWIG_AsVal_int(obj2, &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gpgme_key_sig_get_ulong_attr" "', argument " "3"" of type '" "_gpgme_attr_t""'");
  } 
  arg3 = (_gpgme_attr_t)(val3);
  res4 = SWIG_ConvertPtr(obj3,SWIG_as_voidptrptr(&arg4), 0, 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gpgme_key_sig_get_ulong_attr" "', argument " "4"" of type '" "void const *""'"); 
  }
  ecode5 = SWIG_AsVal_int(obj4, &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gpgme_key_sig_get_ulong_attr" "', argument " "5"" of type '" "int""'");
  } 
  arg5 = (int)(val5);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (unsigned long)gpgme_key_sig_get_ulong_attr(arg1,arg2,arg3,(void const *)arg4,arg5);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_unsigned_SS_long((unsigned long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_import_ext(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  int *arg3 = (int *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  gpgme_data_t wrapper2 = NULL ;
  PyObject *bytesio2 = NULL ;
  Py_buffer view2 ;
  int have_view2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpgme_op_import_ext",&obj0,&obj1,&obj2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_import_ext" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    /* If we create a temporary wrapper2 object, we will store it in
         wrapperN, where N is 2.  Here in this fragment, SWIG will
         automatically append 2.  */
    memset(&view2, 0, sizeof view2);
    if (obj1 == Py_None)
    arg2 = NULL;
    else {
      PyObject *pypointer;
      pypointer = _gpg_obj2gpgme_data_t(obj1, 2, &wrapper2,
        &bytesio2, &view2);
      if (pypointer == NULL)
      return NULL;
      have_view2 = !! view2.obj;
      
      /* input = obj1, 1 = arg2, 1_descriptor = SWIGTYPE_p_gpgme_data */
      
      /* Following code is from swig's python.swg.  */
      
      if ((SWIG_ConvertPtr(pypointer,(void **) &arg2, SWIGTYPE_p_gpgme_data,
            SWIG_POINTER_EXCEPTION | 0 )) == -1) {
        Py_DECREF(pypointer);
        return NULL;
      }
      Py_DECREF(pypointer);
    }
  }
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_int, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_op_import_ext" "', argument " "3"" of type '" "int *""'"); 
  }
  arg3 = (int *)(argp3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_import_ext(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return resultobj;
fail:
  {
    /* See whether we need to update the Python buffer.  */
    if (resultobj && wrapper2 && view2.buf)
    {
      int dirty;
      char *new_data = NULL;
      size_t new_size;
      
      
      new_data = wrapper2->data.mem.buffer;
      new_size = wrapper2->data.mem.length;
      dirty = new_data != NULL;
      
      
      
      
      
      
      
      if (dirty)
      {
        /* The buffer is dirty.  */
        if (view2.readonly)
        {
          Py_XDECREF(resultobj);
          resultobj = NULL;
          PyErr_SetString(PyExc_ValueError,
            "cannot update read-only buffer");
        }
        
        /* See if we need to truncate the buffer.  */
        if (resultobj && view2.len != new_size)
        {
          if (bytesio2 == NULL)
          {
            Py_XDECREF(resultobj);
            resultobj = NULL;
            PyErr_SetString(PyExc_ValueError, "cannot resize buffer");
          }
          else
          {
            PyObject *retval;
            PyBuffer_Release(&view2);
            assert(view2.obj == NULL);
            retval = PyObject_CallMethod(bytesio2, "truncate",
              "l", (long) new_size);
            if (retval == NULL)
            {
              Py_XDECREF(resultobj);
              resultobj = NULL;
            }
            else
            {
              Py_DECREF(retval);
              
              retval = PyObject_CallMethod(bytesio2,
                "getbuffer", NULL);
              if (retval == NULL
                || PyObject_GetBuffer(retval, &view2,
                  PyBUF_SIMPLE|PyBUF_WRITABLE) < 0)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
              }
              
              Py_XDECREF(retval);
              
              if (resultobj && view2.len
                != new_size)
              {
                Py_XDECREF(resultobj);
                resultobj = NULL;
                PyErr_Format(PyExc_ValueError,
                  "Expected buffer of length %zu, got %zi",
                  new_size,
                  view2.len);
              }
            }
          }
        }
        if (resultobj)
        memcpy(view2.buf, new_data, new_size);
      }
      
      
      
    }
    
    /* Free the temporary wrapper, if any.  */
    if (wrapper2)
    gpgme_data_release(wrapper2);
    Py_XDECREF (bytesio2);
    if (have_view2 && view2.buf)
    PyBuffer_Release(&view2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_trust_item_release(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t arg1 = (gpgme_trust_item_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_trust_item_release",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_trust_item_release" "', argument " "1"" of type '" "gpgme_trust_item_t""'"); 
  }
  arg1 = (gpgme_trust_item_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_trust_item_release(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_trust_item_get_string_attr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t arg1 = (gpgme_trust_item_t) 0 ;
  _gpgme_attr_t arg2 ;
  void *arg3 = (void *) 0 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int res3 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  char *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_trust_item_get_string_attr",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_trust_item_get_string_attr" "', argument " "1"" of type '" "gpgme_trust_item_t""'"); 
  }
  arg1 = (gpgme_trust_item_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_trust_item_get_string_attr" "', argument " "2"" of type '" "_gpgme_attr_t""'");
  } 
  arg2 = (_gpgme_attr_t)(val2);
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_trust_item_get_string_attr" "', argument " "3"" of type '" "void const *""'"); 
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_trust_item_get_string_attr" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (char *)gpgme_trust_item_get_string_attr(arg1,arg2,(void const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_trust_item_get_int_attr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t arg1 = (gpgme_trust_item_t) 0 ;
  _gpgme_attr_t arg2 ;
  void *arg3 = (void *) 0 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int res3 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  int result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOO:gpgme_trust_item_get_int_attr",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_trust_item_get_int_attr" "', argument " "1"" of type '" "gpgme_trust_item_t""'"); 
  }
  arg1 = (gpgme_trust_item_t)(argp1);
  ecode2 = SWIG_AsVal_int(obj1, &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gpgme_trust_item_get_int_attr" "', argument " "2"" of type '" "_gpgme_attr_t""'");
  } 
  arg2 = (_gpgme_attr_t)(val2);
  res3 = SWIG_ConvertPtr(obj2,SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpgme_trust_item_get_int_attr" "', argument " "3"" of type '" "void const *""'"); 
  }
  ecode4 = SWIG_AsVal_int(obj3, &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gpgme_trust_item_get_int_attr" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (int)gpgme_trust_item_get_int_attr(arg1,arg2,(void const *)arg3,arg4);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_assuan_result_err_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_assuan_result *arg1 = (struct _gpgme_op_assuan_result *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:_gpgme_op_assuan_result_err_set",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_assuan_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_assuan_result_err_set" "', argument " "1"" of type '" "struct _gpgme_op_assuan_result *""'"); 
  }
  arg1 = (struct _gpgme_op_assuan_result *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    if (arg1) (arg1)->err = arg2;
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gpgme_op_assuan_result_err_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_assuan_result *arg1 = (struct _gpgme_op_assuan_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:_gpgme_op_assuan_result_err_get",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_assuan_result, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gpgme_op_assuan_result_err_get" "', argument " "1"" of type '" "struct _gpgme_op_assuan_result *""'"); 
  }
  arg1 = (struct _gpgme_op_assuan_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result =  ((arg1)->err);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gpgme_op_assuan_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_assuan_result *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new__gpgme_op_assuan_result")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (struct _gpgme_op_assuan_result *)calloc(1, sizeof(struct _gpgme_op_assuan_result));
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_assuan_result, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gpgme_op_assuan_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gpgme_op_assuan_result *arg1 = (struct _gpgme_op_assuan_result *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete__gpgme_op_assuan_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_op_assuan_result, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gpgme_op_assuan_result" "', argument " "1"" of type '" "struct _gpgme_op_assuan_result *""'"); 
  }
  arg1 = (struct _gpgme_op_assuan_result *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    free((char *) arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gpgme_op_assuan_result_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!PyArg_ParseTuple(args,(char *)"O:swigregister", &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gpgme_op_assuan_result, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_gpgme_op_assuan_result(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_assuan_result_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_op_assuan_result",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_assuan_result" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_assuan_result_t)gpgme_op_assuan_result(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_op_assuan_result, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_op_assuan_transact(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  char *arg2 = (char *) 0 ;
  gpgme_assuan_data_cb_t arg3 = (gpgme_assuan_data_cb_t) 0 ;
  void *arg4 = (void *) 0 ;
  gpgme_assuan_inquire_cb_t arg5 = (gpgme_assuan_inquire_cb_t) 0 ;
  void *arg6 = (void *) 0 ;
  gpgme_assuan_status_cb_t arg7 = (gpgme_assuan_status_cb_t) 0 ;
  void *arg8 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  int res8 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject * obj3 = 0 ;
  PyObject * obj4 = 0 ;
  PyObject * obj5 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"OOOOOO:gpgme_op_assuan_transact",&obj0,&obj1,&obj2,&obj3,&obj4,&obj5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_op_assuan_transact" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    if (obj2 == Py_None)
    arg3 = arg4 = NULL;
    else
    {
      if (! PyTuple_Check(obj2))
      return PyErr_Format(PyExc_TypeError, "callback must be a tuple");
      if (PyTuple_Size(obj2) != 2)
      return PyErr_Format(PyExc_TypeError,
        "callback must be a tuple of size 2");
      if (! PyCallable_Check(PyTuple_GetItem(obj2, 1)))
      return PyErr_Format(PyExc_TypeError, "second item must be callable");
      arg3 = _gpg_assuan_data_cb;
      arg4 = obj2;
    }
  }
  {
    if (obj3 == Py_None)
    arg5 = arg6 = NULL;
    else
    {
      if (! PyTuple_Check(obj3))
      return PyErr_Format(PyExc_TypeError, "callback must be a tuple");
      if (PyTuple_Size(obj3) != 2)
      return PyErr_Format(PyExc_TypeError,
        "callback must be a tuple of size 2");
      if (! PyCallable_Check(PyTuple_GetItem(obj3, 1)))
      return PyErr_Format(PyExc_TypeError, "second item must be callable");
      arg5 = _gpg_assuan_inquire_cb;
      arg6 = obj3;
    }
  }
  {
    int res = SWIG_ConvertFunctionPtr(obj4, (void**)(&arg7), SWIGTYPE_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gpgme_op_assuan_transact" "', argument " "7"" of type '" "gpgme_assuan_status_cb_t""'"); 
    }
  }
  res8 = SWIG_ConvertPtr(obj5,SWIG_as_voidptrptr(&arg8), 0, 0);
  if (!SWIG_IsOK(res8)) {
    SWIG_exception_fail(SWIG_ArgError(res8), "in method '" "gpgme_op_assuan_transact" "', argument " "8"" of type '" "void *""'"); 
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_op_assuan_transact(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,arg7,arg8);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_ctx_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_ctx_t_p")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_ctx_t *)new_gpgme_ctx_t_p();
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p_gpgme_context, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_copy_gpgme_ctx_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t arg1 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_ctx_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:copy_gpgme_ctx_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "copy_gpgme_ctx_t_p" "', argument " "1"" of type '" "gpgme_ctx_t""'"); 
  }
  arg1 = (gpgme_ctx_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_ctx_t *)copy_gpgme_ctx_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p_gpgme_context, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_ctx_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t *arg1 = (gpgme_ctx_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_ctx_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_ctx_t_p" "', argument " "1"" of type '" "gpgme_ctx_t *""'"); 
  }
  arg1 = (gpgme_ctx_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    delete_gpgme_ctx_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_ctx_t_p_assign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t *arg1 = (gpgme_ctx_t *) 0 ;
  gpgme_ctx_t arg2 = (gpgme_ctx_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_ctx_t_p_assign",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_ctx_t_p_assign" "', argument " "1"" of type '" "gpgme_ctx_t *""'"); 
  }
  arg1 = (gpgme_ctx_t *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_ctx_t_p_assign" "', argument " "2"" of type '" "gpgme_ctx_t""'"); 
  }
  arg2 = (gpgme_ctx_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_ctx_t_p_assign(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_ctx_t_p_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_ctx_t *arg1 = (gpgme_ctx_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_ctx_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_ctx_t_p_value",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_context, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_ctx_t_p_value" "', argument " "1"" of type '" "gpgme_ctx_t *""'"); 
  }
  arg1 = (gpgme_ctx_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_ctx_t)gpgme_ctx_t_p_value(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_context, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_data_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_data_t_p")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_t *)new_gpgme_data_t_p();
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_copy_gpgme_data_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t arg1 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:copy_gpgme_data_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "copy_gpgme_data_t_p" "', argument " "1"" of type '" "gpgme_data_t""'"); 
  }
  arg1 = (gpgme_data_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_t *)copy_gpgme_data_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_data_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_data_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_data_t_p" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    delete_gpgme_data_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_t_p_assign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  gpgme_data_t arg2 = (gpgme_data_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_data_t_p_assign",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_t_p_assign" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_data_t_p_assign" "', argument " "2"" of type '" "gpgme_data_t""'"); 
  }
  arg2 = (gpgme_data_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_data_t_p_assign(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_data_t_p_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_data_t *arg1 = (gpgme_data_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_data_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_data_t_p_value",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_data_t_p_value" "', argument " "1"" of type '" "gpgme_data_t *""'"); 
  }
  arg1 = (gpgme_data_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_data_t)gpgme_data_t_p_value(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpgme_data, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_key_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_key_t_p")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_key_t *)new_gpgme_key_t_p();
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_copy_gpgme_key_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t arg1 = (gpgme_key_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_key_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:copy_gpgme_key_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "copy_gpgme_key_t_p" "', argument " "1"" of type '" "gpgme_key_t""'"); 
  }
  arg1 = (gpgme_key_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_key_t *)copy_gpgme_key_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_key_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t *arg1 = (gpgme_key_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_key_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_key_t_p" "', argument " "1"" of type '" "gpgme_key_t *""'"); 
  }
  arg1 = (gpgme_key_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    delete_gpgme_key_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_t_p_assign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t *arg1 = (gpgme_key_t *) 0 ;
  gpgme_key_t arg2 = (gpgme_key_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_key_t_p_assign",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_t_p_assign" "', argument " "1"" of type '" "gpgme_key_t *""'"); 
  }
  arg1 = (gpgme_key_t *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_key_t_p_assign" "', argument " "2"" of type '" "gpgme_key_t""'"); 
  }
  arg2 = (gpgme_key_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_key_t_p_assign(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_key_t_p_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_key_t *arg1 = (gpgme_key_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_key_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_key_t_p_value",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_key, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_key_t_p_value" "', argument " "1"" of type '" "gpgme_key_t *""'"); 
  }
  arg1 = (gpgme_key_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_key_t)gpgme_key_t_p_value(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_key, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_error_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_error_t_p")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_error_t *)new_gpgme_error_t_p();
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpg_error_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_copy_gpgme_error_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t arg1 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:copy_gpgme_error_t_p",&obj0)) SWIG_fail;
  {
    if (PyLong_Check(obj0))
    arg1 = PyLong_AsLong(obj0);
    
    else if (PyInt_Check(obj0))
    arg1 = PyInt_AsLong(obj0);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_error_t *)copy_gpgme_error_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gpg_error_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_error_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t *arg1 = (gpgme_error_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_error_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_error_t_p" "', argument " "1"" of type '" "gpgme_error_t *""'"); 
  }
  arg1 = (gpgme_error_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    delete_gpgme_error_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_error_t_p_assign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t *arg1 = (gpgme_error_t *) 0 ;
  gpgme_error_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_error_t_p_assign",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_error_t_p_assign" "', argument " "1"" of type '" "gpgme_error_t *""'"); 
  }
  arg1 = (gpgme_error_t *)(argp1);
  {
    if (PyLong_Check(obj1))
    arg2 = PyLong_AsLong(obj1);
    
    else if (PyInt_Check(obj1))
    arg2 = PyInt_AsLong(obj1);
    
    else
    PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_error_t_p_assign(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_error_t_p_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_error_t *arg1 = (gpgme_error_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_error_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_error_t_p_value",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_gpg_error_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_error_t_p_value" "', argument " "1"" of type '" "gpgme_error_t *""'"); 
  }
  arg1 = (gpgme_error_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = gpgme_error_t_p_value(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    resultobj = PyLong_FromLong(result);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_trust_item_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_trust_item_t_p")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_trust_item_t *)new_gpgme_trust_item_t_p();
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p__gpgme_trust_item, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_copy_gpgme_trust_item_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t arg1 = (gpgme_trust_item_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_trust_item_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:copy_gpgme_trust_item_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "copy_gpgme_trust_item_t_p" "', argument " "1"" of type '" "gpgme_trust_item_t""'"); 
  }
  arg1 = (gpgme_trust_item_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_trust_item_t *)copy_gpgme_trust_item_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p__gpgme_trust_item, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_trust_item_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t *arg1 = (gpgme_trust_item_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_trust_item_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_trust_item_t_p" "', argument " "1"" of type '" "gpgme_trust_item_t *""'"); 
  }
  arg1 = (gpgme_trust_item_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    delete_gpgme_trust_item_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_trust_item_t_p_assign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t *arg1 = (gpgme_trust_item_t *) 0 ;
  gpgme_trust_item_t arg2 = (gpgme_trust_item_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_trust_item_t_p_assign",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_trust_item_t_p_assign" "', argument " "1"" of type '" "gpgme_trust_item_t *""'"); 
  }
  arg1 = (gpgme_trust_item_t *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_trust_item_t_p_assign" "', argument " "2"" of type '" "gpgme_trust_item_t""'"); 
  }
  arg2 = (gpgme_trust_item_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_trust_item_t_p_assign(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_trust_item_t_p_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_trust_item_t *arg1 = (gpgme_trust_item_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_trust_item_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_trust_item_t_p_value",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_trust_item, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_trust_item_t_p_value" "', argument " "1"" of type '" "gpgme_trust_item_t *""'"); 
  }
  arg1 = (gpgme_trust_item_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_trust_item_t)gpgme_trust_item_t_p_value(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gpgme_trust_item, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_gpgme_engine_info_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_engine_info_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)":new_gpgme_engine_info_t_p")) SWIG_fail;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_engine_info_t *)new_gpgme_engine_info_t_p();
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p__gpgme_engine_info, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_copy_gpgme_engine_info_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_engine_info_t arg1 = (gpgme_engine_info_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_engine_info_t *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:copy_gpgme_engine_info_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "copy_gpgme_engine_info_t_p" "', argument " "1"" of type '" "gpgme_engine_info_t""'"); 
  }
  arg1 = (gpgme_engine_info_t)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_engine_info_t *)copy_gpgme_engine_info_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p__gpgme_engine_info, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_gpgme_engine_info_t_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_engine_info_t *arg1 = (gpgme_engine_info_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:delete_gpgme_engine_info_t_p",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_gpgme_engine_info_t_p" "', argument " "1"" of type '" "gpgme_engine_info_t *""'"); 
  }
  arg1 = (gpgme_engine_info_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    delete_gpgme_engine_info_t_p(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_engine_info_t_p_assign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_engine_info_t *arg1 = (gpgme_engine_info_t *) 0 ;
  gpgme_engine_info_t arg2 = (gpgme_engine_info_t) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpgme_engine_info_t_p_assign",&obj0,&obj1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_engine_info_t_p_assign" "', argument " "1"" of type '" "gpgme_engine_info_t *""'"); 
  }
  arg1 = (gpgme_engine_info_t *)(argp1);
  res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gpgme_engine_info_t_p_assign" "', argument " "2"" of type '" "gpgme_engine_info_t""'"); 
  }
  arg2 = (gpgme_engine_info_t)(argp2);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    gpgme_engine_info_t_p_assign(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpgme_engine_info_t_p_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpgme_engine_info_t *arg1 = (gpgme_engine_info_t *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject * obj0 = 0 ;
  gpgme_engine_info_t result;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpgme_engine_info_t_p_value",&obj0)) SWIG_fail;
  res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_p__gpgme_engine_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gpgme_engine_info_t_p_value" "', argument " "1"" of type '" "gpgme_engine_info_t *""'"); 
  }
  arg1 = (gpgme_engine_info_t *)(argp1);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (gpgme_engine_info_t)gpgme_engine_info_t_p_value(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  {
    int i;
    int size = 0;
    gpgme_engine_info_t curr;
    for (curr = result; curr != NULL; curr = curr->next) {
      size++;
    }
    resultobj = PyList_New(size);
    if (resultobj == NULL)
    return NULL;	/* raise */
    for (i=0,curr=result; i<size; i++,curr=curr->next) {
      PyObject *fragile, *o;
      fragile = SWIG_NewPointerObj(SWIG_as_voidptr(curr), SWIGTYPE_p__gpgme_engine_info,
        0 );
      if (fragile == NULL)
      {
        Py_DECREF(resultobj);
        return NULL;	/* raise */
      }
      o = _gpg_wrap_result(fragile, "EngineInfo");
      Py_DECREF(fragile);
      if (o == NULL)
      {
        Py_DECREF(resultobj);
        return NULL;	/* raise */
      }
      PyList_SetItem(resultobj, i, o);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_fdopen(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  int arg1 ;
  char *arg2 = (char *) 0 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *encodedInput2 = NULL ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  FILE *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:fdopen",&obj0,&obj1)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(obj0, &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "fdopen" "', argument " "1"" of type '" "int""'");
  } 
  arg1 = (int)(val1);
  {
    if (obj1 == Py_None)
    arg2 = NULL;
    else if (PyUnicode_Check(obj1))
    {
      encodedInput2 = PyUnicode_AsUTF8String(obj1);
      if (encodedInput2 == NULL)
      return NULL;
      arg2 = PyBytes_AsString(encodedInput2);
    }
    else if (PyBytes_Check(obj1))
    arg2 = PyBytes_AsString(obj1);
    else {
      PyErr_Format(PyExc_TypeError,
        "arg %d: expected str, bytes, or None, got %s",
        2, obj1->ob_type->tp_name);
      return NULL;
    }
  }
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (FILE *)fdopen(arg1,(char const *)arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FILE, 0 |  0 );
  {
    Py_XDECREF(encodedInput2);
  }
  return resultobj;
fail:
  {
    Py_XDECREF(encodedInput2);
  }
  return NULL;
}


SWIGINTERN int Swig_var_gpg_in_tree_build_set(PyObject *_val) {
  {
    int val;
    int res = SWIG_AsVal_int(_val, &val);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in variable '""gpg_in_tree_build""' of type '""int""'");
    }
    gpg_in_tree_build = (int)(val);
  }
  return 0;
fail:
  return 1;
}


SWIGINTERN PyObject *Swig_var_gpg_in_tree_build_get(void) {
  PyObject *pyobj = 0;
  
  pyobj = SWIG_From_int((int)(gpg_in_tree_build));
  return pyobj;
}


SWIGINTERN PyObject *_wrap_gpg_raise_callback_exception(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PyObject *arg1 = (PyObject *) 0 ;
  PyObject * obj0 = 0 ;
  PyObject *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"O:gpg_raise_callback_exception",&obj0)) SWIG_fail;
  arg1 = obj0;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (PyObject *)gpg_raise_callback_exception(arg1);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpg_set_passphrase_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PyObject *arg1 = (PyObject *) 0 ;
  PyObject *arg2 = (PyObject *) 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpg_set_passphrase_cb",&obj0,&obj1)) SWIG_fail;
  arg1 = obj0;
  arg2 = obj1;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (PyObject *)gpg_set_passphrase_cb(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpg_set_progress_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PyObject *arg1 = (PyObject *) 0 ;
  PyObject *arg2 = (PyObject *) 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpg_set_progress_cb",&obj0,&obj1)) SWIG_fail;
  arg1 = obj0;
  arg2 = obj1;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (PyObject *)gpg_set_progress_cb(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpg_set_status_cb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PyObject *arg1 = (PyObject *) 0 ;
  PyObject *arg2 = (PyObject *) 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OO:gpg_set_status_cb",&obj0,&obj1)) SWIG_fail;
  arg1 = obj0;
  arg2 = obj1;
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (PyObject *)gpg_set_status_cb(arg1,arg2);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gpg_data_new_from_cbs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PyObject *arg1 = (PyObject *) 0 ;
  PyObject *arg2 = (PyObject *) 0 ;
  gpgme_data_t *arg3 = (gpgme_data_t *) 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject * obj0 = 0 ;
  PyObject * obj1 = 0 ;
  PyObject * obj2 = 0 ;
  PyObject *result = 0 ;
  
  if (!PyArg_ParseTuple(args,(char *)"OOO:gpg_data_new_from_cbs",&obj0,&obj1,&obj2)) SWIG_fail;
  arg1 = obj0;
  arg2 = obj1;
  res3 = SWIG_ConvertPtr(obj2, &argp3,SWIGTYPE_p_p_gpgme_data, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gpg_data_new_from_cbs" "', argument " "3"" of type '" "gpgme_data_t *""'"); 
  }
  arg3 = (gpgme_data_t *)(argp3);
  {
    SWIG_PYTHON_THREAD_BEGIN_ALLOW;
    result = (PyObject *)gpg_data_new_from_cbs(arg1,arg2,arg3);
    SWIG_PYTHON_THREAD_END_ALLOW;
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


static PyMethodDef SwigMethods[] = {
	 { "SWIG_PyInstanceMethod_New", SWIG_PyInstanceMethod_New, METH_O, NULL},
	 { "gpgme_op_keylist_start", _wrap_gpgme_op_keylist_start, METH_VARARGS, (char *)"gpgme_op_keylist_start(ctx, pattern, secret_only=0) -> gpgme_error_t"},
	 { "gpgme_data_seek", _wrap_gpgme_data_seek, METH_VARARGS, (char *)"gpgme_data_seek(dh, offset, whence) -> off_t"},
	 { "_gpgme_sig_notation_name_set", _wrap__gpgme_sig_notation_name_set, METH_VARARGS, (char *)"_gpgme_sig_notation_name_set(self, name)"},
	 { "_gpgme_sig_notation_name_get", _wrap__gpgme_sig_notation_name_get, METH_VARARGS, (char *)"_gpgme_sig_notation_name_get(self) -> char *"},
	 { "_gpgme_sig_notation_value_set", _wrap__gpgme_sig_notation_value_set, METH_VARARGS, (char *)"_gpgme_sig_notation_value_set(self, value)"},
	 { "_gpgme_sig_notation_value_get", _wrap__gpgme_sig_notation_value_get, METH_VARARGS, (char *)"_gpgme_sig_notation_value_get(self) -> char *"},
	 { "_gpgme_sig_notation_flags_set", _wrap__gpgme_sig_notation_flags_set, METH_VARARGS, (char *)"_gpgme_sig_notation_flags_set(self, flags)"},
	 { "_gpgme_sig_notation_flags_get", _wrap__gpgme_sig_notation_flags_get, METH_VARARGS, (char *)"_gpgme_sig_notation_flags_get(self) -> gpgme_sig_notation_flags_t"},
	 { "_gpgme_sig_notation_human_readable_set", _wrap__gpgme_sig_notation_human_readable_set, METH_VARARGS, (char *)"_gpgme_sig_notation_human_readable_set(self, human_readable)"},
	 { "_gpgme_sig_notation_human_readable_get", _wrap__gpgme_sig_notation_human_readable_get, METH_VARARGS, (char *)"_gpgme_sig_notation_human_readable_get(self) -> unsigned int"},
	 { "_gpgme_sig_notation_critical_set", _wrap__gpgme_sig_notation_critical_set, METH_VARARGS, (char *)"_gpgme_sig_notation_critical_set(self, critical)"},
	 { "_gpgme_sig_notation_critical_get", _wrap__gpgme_sig_notation_critical_get, METH_VARARGS, (char *)"_gpgme_sig_notation_critical_get(self) -> unsigned int"},
	 { "new__gpgme_sig_notation", _wrap_new__gpgme_sig_notation, METH_VARARGS, (char *)"new__gpgme_sig_notation() -> _gpgme_sig_notation"},
	 { "delete__gpgme_sig_notation", _wrap_delete__gpgme_sig_notation, METH_VARARGS, (char *)"delete__gpgme_sig_notation(self)"},
	 { "_gpgme_sig_notation_swigregister", _gpgme_sig_notation_swigregister, METH_VARARGS, NULL},
	 { "gpgme_err_make", _wrap_gpgme_err_make, METH_VARARGS, (char *)"gpgme_err_make(source, code) -> gpgme_error_t"},
	 { "gpgme_error", _wrap_gpgme_error, METH_VARARGS, (char *)"gpgme_error(code) -> gpgme_error_t"},
	 { "gpgme_err_code", _wrap_gpgme_err_code, METH_VARARGS, (char *)"gpgme_err_code(err) -> gpgme_err_code_t"},
	 { "gpgme_err_source", _wrap_gpgme_err_source, METH_VARARGS, (char *)"gpgme_err_source(err) -> gpgme_err_source_t"},
	 { "gpgme_strerror", _wrap_gpgme_strerror, METH_VARARGS, (char *)"gpgme_strerror(err) -> char const *"},
	 { "gpgme_strerror_r", _wrap_gpgme_strerror_r, METH_VARARGS, (char *)"gpgme_strerror_r(err, buf) -> int"},
	 { "gpgme_strsource", _wrap_gpgme_strsource, METH_VARARGS, (char *)"gpgme_strsource(err) -> char const *"},
	 { "gpgme_err_code_from_errno", _wrap_gpgme_err_code_from_errno, METH_VARARGS, (char *)"gpgme_err_code_from_errno(err) -> gpgme_err_code_t"},
	 { "gpgme_err_code_to_errno", _wrap_gpgme_err_code_to_errno, METH_VARARGS, (char *)"gpgme_err_code_to_errno(code) -> int"},
	 { "gpgme_err_code_from_syserror", _wrap_gpgme_err_code_from_syserror, METH_VARARGS, (char *)"gpgme_err_code_from_syserror() -> gpgme_err_code_t"},
	 { "gpgme_err_set_errno", _wrap_gpgme_err_set_errno, METH_VARARGS, (char *)"gpgme_err_set_errno(err)"},
	 { "gpgme_err_make_from_errno", _wrap_gpgme_err_make_from_errno, METH_VARARGS, (char *)"gpgme_err_make_from_errno(source, err) -> gpgme_error_t"},
	 { "gpgme_error_from_errno", _wrap_gpgme_error_from_errno, METH_VARARGS, (char *)"gpgme_error_from_errno(err) -> gpgme_error_t"},
	 { "gpgme_error_from_syserror", _wrap_gpgme_error_from_syserror, METH_VARARGS, (char *)"gpgme_error_from_syserror() -> gpgme_error_t"},
	 { "_gpgme_engine_info_protocol_set", _wrap__gpgme_engine_info_protocol_set, METH_VARARGS, (char *)"_gpgme_engine_info_protocol_set(self, protocol)"},
	 { "_gpgme_engine_info_protocol_get", _wrap__gpgme_engine_info_protocol_get, METH_VARARGS, (char *)"_gpgme_engine_info_protocol_get(self) -> gpgme_protocol_t"},
	 { "_gpgme_engine_info_file_name_set", _wrap__gpgme_engine_info_file_name_set, METH_VARARGS, (char *)"_gpgme_engine_info_file_name_set(self, file_name)"},
	 { "_gpgme_engine_info_file_name_get", _wrap__gpgme_engine_info_file_name_get, METH_VARARGS, (char *)"_gpgme_engine_info_file_name_get(self) -> char *"},
	 { "_gpgme_engine_info_version_set", _wrap__gpgme_engine_info_version_set, METH_VARARGS, (char *)"_gpgme_engine_info_version_set(self, version)"},
	 { "_gpgme_engine_info_version_get", _wrap__gpgme_engine_info_version_get, METH_VARARGS, (char *)"_gpgme_engine_info_version_get(self) -> char *"},
	 { "_gpgme_engine_info_req_version_set", _wrap__gpgme_engine_info_req_version_set, METH_VARARGS, (char *)"_gpgme_engine_info_req_version_set(self, req_version)"},
	 { "_gpgme_engine_info_req_version_get", _wrap__gpgme_engine_info_req_version_get, METH_VARARGS, (char *)"_gpgme_engine_info_req_version_get(self) -> char const *"},
	 { "_gpgme_engine_info_home_dir_set", _wrap__gpgme_engine_info_home_dir_set, METH_VARARGS, (char *)"_gpgme_engine_info_home_dir_set(self, home_dir)"},
	 { "_gpgme_engine_info_home_dir_get", _wrap__gpgme_engine_info_home_dir_get, METH_VARARGS, (char *)"_gpgme_engine_info_home_dir_get(self) -> char *"},
	 { "new__gpgme_engine_info", _wrap_new__gpgme_engine_info, METH_VARARGS, (char *)"new__gpgme_engine_info() -> _gpgme_engine_info"},
	 { "delete__gpgme_engine_info", _wrap_delete__gpgme_engine_info, METH_VARARGS, (char *)"delete__gpgme_engine_info(self)"},
	 { "_gpgme_engine_info_swigregister", _gpgme_engine_info_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_tofu_info_validity_set", _wrap__gpgme_tofu_info_validity_set, METH_VARARGS, (char *)"_gpgme_tofu_info_validity_set(self, validity)"},
	 { "_gpgme_tofu_info_validity_get", _wrap__gpgme_tofu_info_validity_get, METH_VARARGS, (char *)"_gpgme_tofu_info_validity_get(self) -> unsigned int"},
	 { "_gpgme_tofu_info_policy_set", _wrap__gpgme_tofu_info_policy_set, METH_VARARGS, (char *)"_gpgme_tofu_info_policy_set(self, policy)"},
	 { "_gpgme_tofu_info_policy_get", _wrap__gpgme_tofu_info_policy_get, METH_VARARGS, (char *)"_gpgme_tofu_info_policy_get(self) -> unsigned int"},
	 { "_gpgme_tofu_info__rfu_set", _wrap__gpgme_tofu_info__rfu_set, METH_VARARGS, (char *)"_gpgme_tofu_info__rfu_set(self, _rfu)"},
	 { "_gpgme_tofu_info__rfu_get", _wrap__gpgme_tofu_info__rfu_get, METH_VARARGS, (char *)"_gpgme_tofu_info__rfu_get(self) -> unsigned int"},
	 { "_gpgme_tofu_info_signcount_set", _wrap__gpgme_tofu_info_signcount_set, METH_VARARGS, (char *)"_gpgme_tofu_info_signcount_set(self, signcount)"},
	 { "_gpgme_tofu_info_signcount_get", _wrap__gpgme_tofu_info_signcount_get, METH_VARARGS, (char *)"_gpgme_tofu_info_signcount_get(self) -> unsigned short"},
	 { "_gpgme_tofu_info_encrcount_set", _wrap__gpgme_tofu_info_encrcount_set, METH_VARARGS, (char *)"_gpgme_tofu_info_encrcount_set(self, encrcount)"},
	 { "_gpgme_tofu_info_encrcount_get", _wrap__gpgme_tofu_info_encrcount_get, METH_VARARGS, (char *)"_gpgme_tofu_info_encrcount_get(self) -> unsigned short"},
	 { "_gpgme_tofu_info_signfirst_set", _wrap__gpgme_tofu_info_signfirst_set, METH_VARARGS, (char *)"_gpgme_tofu_info_signfirst_set(self, signfirst)"},
	 { "_gpgme_tofu_info_signfirst_get", _wrap__gpgme_tofu_info_signfirst_get, METH_VARARGS, (char *)"_gpgme_tofu_info_signfirst_get(self) -> unsigned long"},
	 { "_gpgme_tofu_info_signlast_set", _wrap__gpgme_tofu_info_signlast_set, METH_VARARGS, (char *)"_gpgme_tofu_info_signlast_set(self, signlast)"},
	 { "_gpgme_tofu_info_signlast_get", _wrap__gpgme_tofu_info_signlast_get, METH_VARARGS, (char *)"_gpgme_tofu_info_signlast_get(self) -> unsigned long"},
	 { "_gpgme_tofu_info_encrfirst_set", _wrap__gpgme_tofu_info_encrfirst_set, METH_VARARGS, (char *)"_gpgme_tofu_info_encrfirst_set(self, encrfirst)"},
	 { "_gpgme_tofu_info_encrfirst_get", _wrap__gpgme_tofu_info_encrfirst_get, METH_VARARGS, (char *)"_gpgme_tofu_info_encrfirst_get(self) -> unsigned long"},
	 { "_gpgme_tofu_info_encrlast_set", _wrap__gpgme_tofu_info_encrlast_set, METH_VARARGS, (char *)"_gpgme_tofu_info_encrlast_set(self, encrlast)"},
	 { "_gpgme_tofu_info_encrlast_get", _wrap__gpgme_tofu_info_encrlast_get, METH_VARARGS, (char *)"_gpgme_tofu_info_encrlast_get(self) -> unsigned long"},
	 { "_gpgme_tofu_info_description_set", _wrap__gpgme_tofu_info_description_set, METH_VARARGS, (char *)"_gpgme_tofu_info_description_set(self, description)"},
	 { "_gpgme_tofu_info_description_get", _wrap__gpgme_tofu_info_description_get, METH_VARARGS, (char *)"_gpgme_tofu_info_description_get(self) -> char *"},
	 { "new__gpgme_tofu_info", _wrap_new__gpgme_tofu_info, METH_VARARGS, (char *)"new__gpgme_tofu_info() -> _gpgme_tofu_info"},
	 { "delete__gpgme_tofu_info", _wrap_delete__gpgme_tofu_info, METH_VARARGS, (char *)"delete__gpgme_tofu_info(self)"},
	 { "_gpgme_tofu_info_swigregister", _gpgme_tofu_info_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_subkey_revoked_set", _wrap__gpgme_subkey_revoked_set, METH_VARARGS, (char *)"_gpgme_subkey_revoked_set(self, revoked)"},
	 { "_gpgme_subkey_revoked_get", _wrap__gpgme_subkey_revoked_get, METH_VARARGS, (char *)"_gpgme_subkey_revoked_get(self) -> unsigned int"},
	 { "_gpgme_subkey_expired_set", _wrap__gpgme_subkey_expired_set, METH_VARARGS, (char *)"_gpgme_subkey_expired_set(self, expired)"},
	 { "_gpgme_subkey_expired_get", _wrap__gpgme_subkey_expired_get, METH_VARARGS, (char *)"_gpgme_subkey_expired_get(self) -> unsigned int"},
	 { "_gpgme_subkey_disabled_set", _wrap__gpgme_subkey_disabled_set, METH_VARARGS, (char *)"_gpgme_subkey_disabled_set(self, disabled)"},
	 { "_gpgme_subkey_disabled_get", _wrap__gpgme_subkey_disabled_get, METH_VARARGS, (char *)"_gpgme_subkey_disabled_get(self) -> unsigned int"},
	 { "_gpgme_subkey_invalid_set", _wrap__gpgme_subkey_invalid_set, METH_VARARGS, (char *)"_gpgme_subkey_invalid_set(self, invalid)"},
	 { "_gpgme_subkey_invalid_get", _wrap__gpgme_subkey_invalid_get, METH_VARARGS, (char *)"_gpgme_subkey_invalid_get(self) -> unsigned int"},
	 { "_gpgme_subkey_can_encrypt_set", _wrap__gpgme_subkey_can_encrypt_set, METH_VARARGS, (char *)"_gpgme_subkey_can_encrypt_set(self, can_encrypt)"},
	 { "_gpgme_subkey_can_encrypt_get", _wrap__gpgme_subkey_can_encrypt_get, METH_VARARGS, (char *)"_gpgme_subkey_can_encrypt_get(self) -> unsigned int"},
	 { "_gpgme_subkey_can_sign_set", _wrap__gpgme_subkey_can_sign_set, METH_VARARGS, (char *)"_gpgme_subkey_can_sign_set(self, can_sign)"},
	 { "_gpgme_subkey_can_sign_get", _wrap__gpgme_subkey_can_sign_get, METH_VARARGS, (char *)"_gpgme_subkey_can_sign_get(self) -> unsigned int"},
	 { "_gpgme_subkey_can_certify_set", _wrap__gpgme_subkey_can_certify_set, METH_VARARGS, (char *)"_gpgme_subkey_can_certify_set(self, can_certify)"},
	 { "_gpgme_subkey_can_certify_get", _wrap__gpgme_subkey_can_certify_get, METH_VARARGS, (char *)"_gpgme_subkey_can_certify_get(self) -> unsigned int"},
	 { "_gpgme_subkey_secret_set", _wrap__gpgme_subkey_secret_set, METH_VARARGS, (char *)"_gpgme_subkey_secret_set(self, secret)"},
	 { "_gpgme_subkey_secret_get", _wrap__gpgme_subkey_secret_get, METH_VARARGS, (char *)"_gpgme_subkey_secret_get(self) -> unsigned int"},
	 { "_gpgme_subkey_can_authenticate_set", _wrap__gpgme_subkey_can_authenticate_set, METH_VARARGS, (char *)"_gpgme_subkey_can_authenticate_set(self, can_authenticate)"},
	 { "_gpgme_subkey_can_authenticate_get", _wrap__gpgme_subkey_can_authenticate_get, METH_VARARGS, (char *)"_gpgme_subkey_can_authenticate_get(self) -> unsigned int"},
	 { "_gpgme_subkey_is_qualified_set", _wrap__gpgme_subkey_is_qualified_set, METH_VARARGS, (char *)"_gpgme_subkey_is_qualified_set(self, is_qualified)"},
	 { "_gpgme_subkey_is_qualified_get", _wrap__gpgme_subkey_is_qualified_get, METH_VARARGS, (char *)"_gpgme_subkey_is_qualified_get(self) -> unsigned int"},
	 { "_gpgme_subkey_is_cardkey_set", _wrap__gpgme_subkey_is_cardkey_set, METH_VARARGS, (char *)"_gpgme_subkey_is_cardkey_set(self, is_cardkey)"},
	 { "_gpgme_subkey_is_cardkey_get", _wrap__gpgme_subkey_is_cardkey_get, METH_VARARGS, (char *)"_gpgme_subkey_is_cardkey_get(self) -> unsigned int"},
	 { "_gpgme_subkey_is_de_vs_set", _wrap__gpgme_subkey_is_de_vs_set, METH_VARARGS, (char *)"_gpgme_subkey_is_de_vs_set(self, is_de_vs)"},
	 { "_gpgme_subkey_is_de_vs_get", _wrap__gpgme_subkey_is_de_vs_get, METH_VARARGS, (char *)"_gpgme_subkey_is_de_vs_get(self) -> unsigned int"},
	 { "_gpgme_subkey__unused_set", _wrap__gpgme_subkey__unused_set, METH_VARARGS, (char *)"_gpgme_subkey__unused_set(self, _unused)"},
	 { "_gpgme_subkey__unused_get", _wrap__gpgme_subkey__unused_get, METH_VARARGS, (char *)"_gpgme_subkey__unused_get(self) -> unsigned int"},
	 { "_gpgme_subkey_pubkey_algo_set", _wrap__gpgme_subkey_pubkey_algo_set, METH_VARARGS, (char *)"_gpgme_subkey_pubkey_algo_set(self, pubkey_algo)"},
	 { "_gpgme_subkey_pubkey_algo_get", _wrap__gpgme_subkey_pubkey_algo_get, METH_VARARGS, (char *)"_gpgme_subkey_pubkey_algo_get(self) -> gpgme_pubkey_algo_t"},
	 { "_gpgme_subkey_length_set", _wrap__gpgme_subkey_length_set, METH_VARARGS, (char *)"_gpgme_subkey_length_set(self, length)"},
	 { "_gpgme_subkey_length_get", _wrap__gpgme_subkey_length_get, METH_VARARGS, (char *)"_gpgme_subkey_length_get(self) -> unsigned int"},
	 { "_gpgme_subkey_keyid_set", _wrap__gpgme_subkey_keyid_set, METH_VARARGS, (char *)"_gpgme_subkey_keyid_set(self, keyid)"},
	 { "_gpgme_subkey_keyid_get", _wrap__gpgme_subkey_keyid_get, METH_VARARGS, (char *)"_gpgme_subkey_keyid_get(self) -> char *"},
	 { "_gpgme_subkey__keyid_set", _wrap__gpgme_subkey__keyid_set, METH_VARARGS, (char *)"_gpgme_subkey__keyid_set(self, _keyid)"},
	 { "_gpgme_subkey__keyid_get", _wrap__gpgme_subkey__keyid_get, METH_VARARGS, (char *)"_gpgme_subkey__keyid_get(self) -> char [16+1]"},
	 { "_gpgme_subkey_fpr_set", _wrap__gpgme_subkey_fpr_set, METH_VARARGS, (char *)"_gpgme_subkey_fpr_set(self, fpr)"},
	 { "_gpgme_subkey_fpr_get", _wrap__gpgme_subkey_fpr_get, METH_VARARGS, (char *)"_gpgme_subkey_fpr_get(self) -> char *"},
	 { "_gpgme_subkey_timestamp_set", _wrap__gpgme_subkey_timestamp_set, METH_VARARGS, (char *)"_gpgme_subkey_timestamp_set(self, timestamp)"},
	 { "_gpgme_subkey_timestamp_get", _wrap__gpgme_subkey_timestamp_get, METH_VARARGS, (char *)"_gpgme_subkey_timestamp_get(self) -> long"},
	 { "_gpgme_subkey_expires_set", _wrap__gpgme_subkey_expires_set, METH_VARARGS, (char *)"_gpgme_subkey_expires_set(self, expires)"},
	 { "_gpgme_subkey_expires_get", _wrap__gpgme_subkey_expires_get, METH_VARARGS, (char *)"_gpgme_subkey_expires_get(self) -> long"},
	 { "_gpgme_subkey_card_number_set", _wrap__gpgme_subkey_card_number_set, METH_VARARGS, (char *)"_gpgme_subkey_card_number_set(self, card_number)"},
	 { "_gpgme_subkey_card_number_get", _wrap__gpgme_subkey_card_number_get, METH_VARARGS, (char *)"_gpgme_subkey_card_number_get(self) -> char *"},
	 { "_gpgme_subkey_curve_set", _wrap__gpgme_subkey_curve_set, METH_VARARGS, (char *)"_gpgme_subkey_curve_set(self, curve)"},
	 { "_gpgme_subkey_curve_get", _wrap__gpgme_subkey_curve_get, METH_VARARGS, (char *)"_gpgme_subkey_curve_get(self) -> char *"},
	 { "_gpgme_subkey_keygrip_set", _wrap__gpgme_subkey_keygrip_set, METH_VARARGS, (char *)"_gpgme_subkey_keygrip_set(self, keygrip)"},
	 { "_gpgme_subkey_keygrip_get", _wrap__gpgme_subkey_keygrip_get, METH_VARARGS, (char *)"_gpgme_subkey_keygrip_get(self) -> char *"},
	 { "new__gpgme_subkey", _wrap_new__gpgme_subkey, METH_VARARGS, (char *)"new__gpgme_subkey() -> _gpgme_subkey"},
	 { "delete__gpgme_subkey", _wrap_delete__gpgme_subkey, METH_VARARGS, (char *)"delete__gpgme_subkey(self)"},
	 { "_gpgme_subkey_swigregister", _gpgme_subkey_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_key_sig_revoked_set", _wrap__gpgme_key_sig_revoked_set, METH_VARARGS, (char *)"_gpgme_key_sig_revoked_set(self, revoked)"},
	 { "_gpgme_key_sig_revoked_get", _wrap__gpgme_key_sig_revoked_get, METH_VARARGS, (char *)"_gpgme_key_sig_revoked_get(self) -> unsigned int"},
	 { "_gpgme_key_sig_expired_set", _wrap__gpgme_key_sig_expired_set, METH_VARARGS, (char *)"_gpgme_key_sig_expired_set(self, expired)"},
	 { "_gpgme_key_sig_expired_get", _wrap__gpgme_key_sig_expired_get, METH_VARARGS, (char *)"_gpgme_key_sig_expired_get(self) -> unsigned int"},
	 { "_gpgme_key_sig_invalid_set", _wrap__gpgme_key_sig_invalid_set, METH_VARARGS, (char *)"_gpgme_key_sig_invalid_set(self, invalid)"},
	 { "_gpgme_key_sig_invalid_get", _wrap__gpgme_key_sig_invalid_get, METH_VARARGS, (char *)"_gpgme_key_sig_invalid_get(self) -> unsigned int"},
	 { "_gpgme_key_sig_exportable_set", _wrap__gpgme_key_sig_exportable_set, METH_VARARGS, (char *)"_gpgme_key_sig_exportable_set(self, exportable)"},
	 { "_gpgme_key_sig_exportable_get", _wrap__gpgme_key_sig_exportable_get, METH_VARARGS, (char *)"_gpgme_key_sig_exportable_get(self) -> unsigned int"},
	 { "_gpgme_key_sig__unused_set", _wrap__gpgme_key_sig__unused_set, METH_VARARGS, (char *)"_gpgme_key_sig__unused_set(self, _unused)"},
	 { "_gpgme_key_sig__unused_get", _wrap__gpgme_key_sig__unused_get, METH_VARARGS, (char *)"_gpgme_key_sig__unused_get(self) -> unsigned int"},
	 { "_gpgme_key_sig_pubkey_algo_set", _wrap__gpgme_key_sig_pubkey_algo_set, METH_VARARGS, (char *)"_gpgme_key_sig_pubkey_algo_set(self, pubkey_algo)"},
	 { "_gpgme_key_sig_pubkey_algo_get", _wrap__gpgme_key_sig_pubkey_algo_get, METH_VARARGS, (char *)"_gpgme_key_sig_pubkey_algo_get(self) -> gpgme_pubkey_algo_t"},
	 { "_gpgme_key_sig_keyid_set", _wrap__gpgme_key_sig_keyid_set, METH_VARARGS, (char *)"_gpgme_key_sig_keyid_set(self, keyid)"},
	 { "_gpgme_key_sig_keyid_get", _wrap__gpgme_key_sig_keyid_get, METH_VARARGS, (char *)"_gpgme_key_sig_keyid_get(self) -> char *"},
	 { "_gpgme_key_sig__keyid_set", _wrap__gpgme_key_sig__keyid_set, METH_VARARGS, (char *)"_gpgme_key_sig__keyid_set(self, _keyid)"},
	 { "_gpgme_key_sig__keyid_get", _wrap__gpgme_key_sig__keyid_get, METH_VARARGS, (char *)"_gpgme_key_sig__keyid_get(self) -> char [16+1]"},
	 { "_gpgme_key_sig_timestamp_set", _wrap__gpgme_key_sig_timestamp_set, METH_VARARGS, (char *)"_gpgme_key_sig_timestamp_set(self, timestamp)"},
	 { "_gpgme_key_sig_timestamp_get", _wrap__gpgme_key_sig_timestamp_get, METH_VARARGS, (char *)"_gpgme_key_sig_timestamp_get(self) -> long"},
	 { "_gpgme_key_sig_expires_set", _wrap__gpgme_key_sig_expires_set, METH_VARARGS, (char *)"_gpgme_key_sig_expires_set(self, expires)"},
	 { "_gpgme_key_sig_expires_get", _wrap__gpgme_key_sig_expires_get, METH_VARARGS, (char *)"_gpgme_key_sig_expires_get(self) -> long"},
	 { "_gpgme_key_sig_status_set", _wrap__gpgme_key_sig_status_set, METH_VARARGS, (char *)"_gpgme_key_sig_status_set(self, status)"},
	 { "_gpgme_key_sig_status_get", _wrap__gpgme_key_sig_status_get, METH_VARARGS, (char *)"_gpgme_key_sig_status_get(self) -> gpgme_error_t"},
	 { "_gpgme_key_sig__obsolete_class_set", _wrap__gpgme_key_sig__obsolete_class_set, METH_VARARGS, (char *)"_gpgme_key_sig__obsolete_class_set(self, _obsolete_class)"},
	 { "_gpgme_key_sig__obsolete_class_get", _wrap__gpgme_key_sig__obsolete_class_get, METH_VARARGS, (char *)"_gpgme_key_sig__obsolete_class_get(self) -> unsigned int"},
	 { "_gpgme_key_sig_uid_set", _wrap__gpgme_key_sig_uid_set, METH_VARARGS, (char *)"_gpgme_key_sig_uid_set(self, uid)"},
	 { "_gpgme_key_sig_uid_get", _wrap__gpgme_key_sig_uid_get, METH_VARARGS, (char *)"_gpgme_key_sig_uid_get(self) -> char *"},
	 { "_gpgme_key_sig_name_set", _wrap__gpgme_key_sig_name_set, METH_VARARGS, (char *)"_gpgme_key_sig_name_set(self, name)"},
	 { "_gpgme_key_sig_name_get", _wrap__gpgme_key_sig_name_get, METH_VARARGS, (char *)"_gpgme_key_sig_name_get(self) -> char *"},
	 { "_gpgme_key_sig_email_set", _wrap__gpgme_key_sig_email_set, METH_VARARGS, (char *)"_gpgme_key_sig_email_set(self, email)"},
	 { "_gpgme_key_sig_email_get", _wrap__gpgme_key_sig_email_get, METH_VARARGS, (char *)"_gpgme_key_sig_email_get(self) -> char *"},
	 { "_gpgme_key_sig_comment_set", _wrap__gpgme_key_sig_comment_set, METH_VARARGS, (char *)"_gpgme_key_sig_comment_set(self, comment)"},
	 { "_gpgme_key_sig_comment_get", _wrap__gpgme_key_sig_comment_get, METH_VARARGS, (char *)"_gpgme_key_sig_comment_get(self) -> char *"},
	 { "_gpgme_key_sig_sig_class_set", _wrap__gpgme_key_sig_sig_class_set, METH_VARARGS, (char *)"_gpgme_key_sig_sig_class_set(self, sig_class)"},
	 { "_gpgme_key_sig_sig_class_get", _wrap__gpgme_key_sig_sig_class_get, METH_VARARGS, (char *)"_gpgme_key_sig_sig_class_get(self) -> unsigned int"},
	 { "_gpgme_key_sig_notations_set", _wrap__gpgme_key_sig_notations_set, METH_VARARGS, (char *)"_gpgme_key_sig_notations_set(self, notations)"},
	 { "_gpgme_key_sig_notations_get", _wrap__gpgme_key_sig_notations_get, METH_VARARGS, (char *)"_gpgme_key_sig_notations_get(self) -> _gpgme_sig_notation"},
	 { "_gpgme_key_sig__last_notation_set", _wrap__gpgme_key_sig__last_notation_set, METH_VARARGS, (char *)"_gpgme_key_sig__last_notation_set(self, _last_notation)"},
	 { "_gpgme_key_sig__last_notation_get", _wrap__gpgme_key_sig__last_notation_get, METH_VARARGS, (char *)"_gpgme_key_sig__last_notation_get(self) -> _gpgme_sig_notation"},
	 { "new__gpgme_key_sig", _wrap_new__gpgme_key_sig, METH_VARARGS, (char *)"new__gpgme_key_sig() -> _gpgme_key_sig"},
	 { "delete__gpgme_key_sig", _wrap_delete__gpgme_key_sig, METH_VARARGS, (char *)"delete__gpgme_key_sig(self)"},
	 { "_gpgme_key_sig_swigregister", _gpgme_key_sig_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_user_id_revoked_set", _wrap__gpgme_user_id_revoked_set, METH_VARARGS, (char *)"_gpgme_user_id_revoked_set(self, revoked)"},
	 { "_gpgme_user_id_revoked_get", _wrap__gpgme_user_id_revoked_get, METH_VARARGS, (char *)"_gpgme_user_id_revoked_get(self) -> unsigned int"},
	 { "_gpgme_user_id_invalid_set", _wrap__gpgme_user_id_invalid_set, METH_VARARGS, (char *)"_gpgme_user_id_invalid_set(self, invalid)"},
	 { "_gpgme_user_id_invalid_get", _wrap__gpgme_user_id_invalid_get, METH_VARARGS, (char *)"_gpgme_user_id_invalid_get(self) -> unsigned int"},
	 { "_gpgme_user_id__unused_set", _wrap__gpgme_user_id__unused_set, METH_VARARGS, (char *)"_gpgme_user_id__unused_set(self, _unused)"},
	 { "_gpgme_user_id__unused_get", _wrap__gpgme_user_id__unused_get, METH_VARARGS, (char *)"_gpgme_user_id__unused_get(self) -> unsigned int"},
	 { "_gpgme_user_id_origin_set", _wrap__gpgme_user_id_origin_set, METH_VARARGS, (char *)"_gpgme_user_id_origin_set(self, origin)"},
	 { "_gpgme_user_id_origin_get", _wrap__gpgme_user_id_origin_get, METH_VARARGS, (char *)"_gpgme_user_id_origin_get(self) -> unsigned int"},
	 { "_gpgme_user_id_validity_set", _wrap__gpgme_user_id_validity_set, METH_VARARGS, (char *)"_gpgme_user_id_validity_set(self, validity)"},
	 { "_gpgme_user_id_validity_get", _wrap__gpgme_user_id_validity_get, METH_VARARGS, (char *)"_gpgme_user_id_validity_get(self) -> gpgme_validity_t"},
	 { "_gpgme_user_id_uid_set", _wrap__gpgme_user_id_uid_set, METH_VARARGS, (char *)"_gpgme_user_id_uid_set(self, uid)"},
	 { "_gpgme_user_id_uid_get", _wrap__gpgme_user_id_uid_get, METH_VARARGS, (char *)"_gpgme_user_id_uid_get(self) -> char *"},
	 { "_gpgme_user_id_name_set", _wrap__gpgme_user_id_name_set, METH_VARARGS, (char *)"_gpgme_user_id_name_set(self, name)"},
	 { "_gpgme_user_id_name_get", _wrap__gpgme_user_id_name_get, METH_VARARGS, (char *)"_gpgme_user_id_name_get(self) -> char *"},
	 { "_gpgme_user_id_email_set", _wrap__gpgme_user_id_email_set, METH_VARARGS, (char *)"_gpgme_user_id_email_set(self, email)"},
	 { "_gpgme_user_id_email_get", _wrap__gpgme_user_id_email_get, METH_VARARGS, (char *)"_gpgme_user_id_email_get(self) -> char *"},
	 { "_gpgme_user_id_comment_set", _wrap__gpgme_user_id_comment_set, METH_VARARGS, (char *)"_gpgme_user_id_comment_set(self, comment)"},
	 { "_gpgme_user_id_comment_get", _wrap__gpgme_user_id_comment_get, METH_VARARGS, (char *)"_gpgme_user_id_comment_get(self) -> char *"},
	 { "_gpgme_user_id_signatures_set", _wrap__gpgme_user_id_signatures_set, METH_VARARGS, (char *)"_gpgme_user_id_signatures_set(self, signatures)"},
	 { "_gpgme_user_id_signatures_get", _wrap__gpgme_user_id_signatures_get, METH_VARARGS, (char *)"_gpgme_user_id_signatures_get(self) -> _gpgme_key_sig"},
	 { "_gpgme_user_id__last_keysig_set", _wrap__gpgme_user_id__last_keysig_set, METH_VARARGS, (char *)"_gpgme_user_id__last_keysig_set(self, _last_keysig)"},
	 { "_gpgme_user_id__last_keysig_get", _wrap__gpgme_user_id__last_keysig_get, METH_VARARGS, (char *)"_gpgme_user_id__last_keysig_get(self) -> _gpgme_key_sig"},
	 { "_gpgme_user_id_address_set", _wrap__gpgme_user_id_address_set, METH_VARARGS, (char *)"_gpgme_user_id_address_set(self, address)"},
	 { "_gpgme_user_id_address_get", _wrap__gpgme_user_id_address_get, METH_VARARGS, (char *)"_gpgme_user_id_address_get(self) -> char *"},
	 { "_gpgme_user_id_tofu_set", _wrap__gpgme_user_id_tofu_set, METH_VARARGS, (char *)"_gpgme_user_id_tofu_set(self, tofu)"},
	 { "_gpgme_user_id_tofu_get", _wrap__gpgme_user_id_tofu_get, METH_VARARGS, (char *)"_gpgme_user_id_tofu_get(self) -> _gpgme_tofu_info"},
	 { "_gpgme_user_id_last_update_set", _wrap__gpgme_user_id_last_update_set, METH_VARARGS, (char *)"_gpgme_user_id_last_update_set(self, last_update)"},
	 { "_gpgme_user_id_last_update_get", _wrap__gpgme_user_id_last_update_get, METH_VARARGS, (char *)"_gpgme_user_id_last_update_get(self) -> unsigned long"},
	 { "new__gpgme_user_id", _wrap_new__gpgme_user_id, METH_VARARGS, (char *)"new__gpgme_user_id() -> _gpgme_user_id"},
	 { "delete__gpgme_user_id", _wrap_delete__gpgme_user_id, METH_VARARGS, (char *)"delete__gpgme_user_id(self)"},
	 { "_gpgme_user_id_swigregister", _gpgme_user_id_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_key__refs_set", _wrap__gpgme_key__refs_set, METH_VARARGS, (char *)"_gpgme_key__refs_set(self, _refs)"},
	 { "_gpgme_key__refs_get", _wrap__gpgme_key__refs_get, METH_VARARGS, (char *)"_gpgme_key__refs_get(self) -> unsigned int"},
	 { "_gpgme_key_revoked_set", _wrap__gpgme_key_revoked_set, METH_VARARGS, (char *)"_gpgme_key_revoked_set(self, revoked)"},
	 { "_gpgme_key_revoked_get", _wrap__gpgme_key_revoked_get, METH_VARARGS, (char *)"_gpgme_key_revoked_get(self) -> unsigned int"},
	 { "_gpgme_key_expired_set", _wrap__gpgme_key_expired_set, METH_VARARGS, (char *)"_gpgme_key_expired_set(self, expired)"},
	 { "_gpgme_key_expired_get", _wrap__gpgme_key_expired_get, METH_VARARGS, (char *)"_gpgme_key_expired_get(self) -> unsigned int"},
	 { "_gpgme_key_disabled_set", _wrap__gpgme_key_disabled_set, METH_VARARGS, (char *)"_gpgme_key_disabled_set(self, disabled)"},
	 { "_gpgme_key_disabled_get", _wrap__gpgme_key_disabled_get, METH_VARARGS, (char *)"_gpgme_key_disabled_get(self) -> unsigned int"},
	 { "_gpgme_key_invalid_set", _wrap__gpgme_key_invalid_set, METH_VARARGS, (char *)"_gpgme_key_invalid_set(self, invalid)"},
	 { "_gpgme_key_invalid_get", _wrap__gpgme_key_invalid_get, METH_VARARGS, (char *)"_gpgme_key_invalid_get(self) -> unsigned int"},
	 { "_gpgme_key_can_encrypt_set", _wrap__gpgme_key_can_encrypt_set, METH_VARARGS, (char *)"_gpgme_key_can_encrypt_set(self, can_encrypt)"},
	 { "_gpgme_key_can_encrypt_get", _wrap__gpgme_key_can_encrypt_get, METH_VARARGS, (char *)"_gpgme_key_can_encrypt_get(self) -> unsigned int"},
	 { "_gpgme_key_can_sign_set", _wrap__gpgme_key_can_sign_set, METH_VARARGS, (char *)"_gpgme_key_can_sign_set(self, can_sign)"},
	 { "_gpgme_key_can_sign_get", _wrap__gpgme_key_can_sign_get, METH_VARARGS, (char *)"_gpgme_key_can_sign_get(self) -> unsigned int"},
	 { "_gpgme_key_can_certify_set", _wrap__gpgme_key_can_certify_set, METH_VARARGS, (char *)"_gpgme_key_can_certify_set(self, can_certify)"},
	 { "_gpgme_key_can_certify_get", _wrap__gpgme_key_can_certify_get, METH_VARARGS, (char *)"_gpgme_key_can_certify_get(self) -> unsigned int"},
	 { "_gpgme_key_secret_set", _wrap__gpgme_key_secret_set, METH_VARARGS, (char *)"_gpgme_key_secret_set(self, secret)"},
	 { "_gpgme_key_secret_get", _wrap__gpgme_key_secret_get, METH_VARARGS, (char *)"_gpgme_key_secret_get(self) -> unsigned int"},
	 { "_gpgme_key_can_authenticate_set", _wrap__gpgme_key_can_authenticate_set, METH_VARARGS, (char *)"_gpgme_key_can_authenticate_set(self, can_authenticate)"},
	 { "_gpgme_key_can_authenticate_get", _wrap__gpgme_key_can_authenticate_get, METH_VARARGS, (char *)"_gpgme_key_can_authenticate_get(self) -> unsigned int"},
	 { "_gpgme_key_is_qualified_set", _wrap__gpgme_key_is_qualified_set, METH_VARARGS, (char *)"_gpgme_key_is_qualified_set(self, is_qualified)"},
	 { "_gpgme_key_is_qualified_get", _wrap__gpgme_key_is_qualified_get, METH_VARARGS, (char *)"_gpgme_key_is_qualified_get(self) -> unsigned int"},
	 { "_gpgme_key__unused_set", _wrap__gpgme_key__unused_set, METH_VARARGS, (char *)"_gpgme_key__unused_set(self, _unused)"},
	 { "_gpgme_key__unused_get", _wrap__gpgme_key__unused_get, METH_VARARGS, (char *)"_gpgme_key__unused_get(self) -> unsigned int"},
	 { "_gpgme_key_origin_set", _wrap__gpgme_key_origin_set, METH_VARARGS, (char *)"_gpgme_key_origin_set(self, origin)"},
	 { "_gpgme_key_origin_get", _wrap__gpgme_key_origin_get, METH_VARARGS, (char *)"_gpgme_key_origin_get(self) -> unsigned int"},
	 { "_gpgme_key_protocol_set", _wrap__gpgme_key_protocol_set, METH_VARARGS, (char *)"_gpgme_key_protocol_set(self, protocol)"},
	 { "_gpgme_key_protocol_get", _wrap__gpgme_key_protocol_get, METH_VARARGS, (char *)"_gpgme_key_protocol_get(self) -> gpgme_protocol_t"},
	 { "_gpgme_key_issuer_serial_set", _wrap__gpgme_key_issuer_serial_set, METH_VARARGS, (char *)"_gpgme_key_issuer_serial_set(self, issuer_serial)"},
	 { "_gpgme_key_issuer_serial_get", _wrap__gpgme_key_issuer_serial_get, METH_VARARGS, (char *)"_gpgme_key_issuer_serial_get(self) -> char *"},
	 { "_gpgme_key_issuer_name_set", _wrap__gpgme_key_issuer_name_set, METH_VARARGS, (char *)"_gpgme_key_issuer_name_set(self, issuer_name)"},
	 { "_gpgme_key_issuer_name_get", _wrap__gpgme_key_issuer_name_get, METH_VARARGS, (char *)"_gpgme_key_issuer_name_get(self) -> char *"},
	 { "_gpgme_key_chain_id_set", _wrap__gpgme_key_chain_id_set, METH_VARARGS, (char *)"_gpgme_key_chain_id_set(self, chain_id)"},
	 { "_gpgme_key_chain_id_get", _wrap__gpgme_key_chain_id_get, METH_VARARGS, (char *)"_gpgme_key_chain_id_get(self) -> char *"},
	 { "_gpgme_key_owner_trust_set", _wrap__gpgme_key_owner_trust_set, METH_VARARGS, (char *)"_gpgme_key_owner_trust_set(self, owner_trust)"},
	 { "_gpgme_key_owner_trust_get", _wrap__gpgme_key_owner_trust_get, METH_VARARGS, (char *)"_gpgme_key_owner_trust_get(self) -> gpgme_validity_t"},
	 { "_gpgme_key_subkeys_set", _wrap__gpgme_key_subkeys_set, METH_VARARGS, (char *)"_gpgme_key_subkeys_set(self, subkeys)"},
	 { "_gpgme_key_subkeys_get", _wrap__gpgme_key_subkeys_get, METH_VARARGS, (char *)"_gpgme_key_subkeys_get(self) -> _gpgme_subkey"},
	 { "_gpgme_key_uids_set", _wrap__gpgme_key_uids_set, METH_VARARGS, (char *)"_gpgme_key_uids_set(self, uids)"},
	 { "_gpgme_key_uids_get", _wrap__gpgme_key_uids_get, METH_VARARGS, (char *)"_gpgme_key_uids_get(self) -> _gpgme_user_id"},
	 { "_gpgme_key__last_subkey_set", _wrap__gpgme_key__last_subkey_set, METH_VARARGS, (char *)"_gpgme_key__last_subkey_set(self, _last_subkey)"},
	 { "_gpgme_key__last_subkey_get", _wrap__gpgme_key__last_subkey_get, METH_VARARGS, (char *)"_gpgme_key__last_subkey_get(self) -> _gpgme_subkey"},
	 { "_gpgme_key__last_uid_set", _wrap__gpgme_key__last_uid_set, METH_VARARGS, (char *)"_gpgme_key__last_uid_set(self, _last_uid)"},
	 { "_gpgme_key__last_uid_get", _wrap__gpgme_key__last_uid_get, METH_VARARGS, (char *)"_gpgme_key__last_uid_get(self) -> _gpgme_user_id"},
	 { "_gpgme_key_keylist_mode_set", _wrap__gpgme_key_keylist_mode_set, METH_VARARGS, (char *)"_gpgme_key_keylist_mode_set(self, keylist_mode)"},
	 { "_gpgme_key_keylist_mode_get", _wrap__gpgme_key_keylist_mode_get, METH_VARARGS, (char *)"_gpgme_key_keylist_mode_get(self) -> gpgme_keylist_mode_t"},
	 { "_gpgme_key_fpr_set", _wrap__gpgme_key_fpr_set, METH_VARARGS, (char *)"_gpgme_key_fpr_set(self, fpr)"},
	 { "_gpgme_key_fpr_get", _wrap__gpgme_key_fpr_get, METH_VARARGS, (char *)"_gpgme_key_fpr_get(self) -> char *"},
	 { "_gpgme_key_last_update_set", _wrap__gpgme_key_last_update_set, METH_VARARGS, (char *)"_gpgme_key_last_update_set(self, last_update)"},
	 { "_gpgme_key_last_update_get", _wrap__gpgme_key_last_update_get, METH_VARARGS, (char *)"_gpgme_key_last_update_get(self) -> unsigned long"},
	 { "new__gpgme_key", _wrap_new__gpgme_key, METH_VARARGS, (char *)"new__gpgme_key() -> _gpgme_key"},
	 { "delete__gpgme_key", _wrap_delete__gpgme_key, METH_VARARGS, (char *)"delete__gpgme_key(self)"},
	 { "_gpgme_key_swigregister", _gpgme_key_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_invalid_key_fpr_set", _wrap__gpgme_invalid_key_fpr_set, METH_VARARGS, (char *)"_gpgme_invalid_key_fpr_set(self, fpr)"},
	 { "_gpgme_invalid_key_fpr_get", _wrap__gpgme_invalid_key_fpr_get, METH_VARARGS, (char *)"_gpgme_invalid_key_fpr_get(self) -> char *"},
	 { "_gpgme_invalid_key_reason_set", _wrap__gpgme_invalid_key_reason_set, METH_VARARGS, (char *)"_gpgme_invalid_key_reason_set(self, reason)"},
	 { "_gpgme_invalid_key_reason_get", _wrap__gpgme_invalid_key_reason_get, METH_VARARGS, (char *)"_gpgme_invalid_key_reason_get(self) -> gpgme_error_t"},
	 { "new__gpgme_invalid_key", _wrap_new__gpgme_invalid_key, METH_VARARGS, (char *)"new__gpgme_invalid_key() -> _gpgme_invalid_key"},
	 { "delete__gpgme_invalid_key", _wrap_delete__gpgme_invalid_key, METH_VARARGS, (char *)"delete__gpgme_invalid_key(self)"},
	 { "_gpgme_invalid_key_swigregister", _gpgme_invalid_key_swigregister, METH_VARARGS, NULL},
	 { "gpgme_new", _wrap_gpgme_new, METH_VARARGS, (char *)"gpgme_new(ctx) -> gpgme_error_t"},
	 { "gpgme_release", _wrap_gpgme_release, METH_VARARGS, (char *)"gpgme_release(ctx)"},
	 { "gpgme_set_ctx_flag", _wrap_gpgme_set_ctx_flag, METH_VARARGS, (char *)"gpgme_set_ctx_flag(ctx, name, value) -> gpgme_error_t"},
	 { "gpgme_get_ctx_flag", _wrap_gpgme_get_ctx_flag, METH_VARARGS, (char *)"gpgme_get_ctx_flag(ctx, name) -> char const *"},
	 { "gpgme_set_protocol", _wrap_gpgme_set_protocol, METH_VARARGS, (char *)"gpgme_set_protocol(ctx, proto) -> gpgme_error_t"},
	 { "gpgme_get_protocol", _wrap_gpgme_get_protocol, METH_VARARGS, (char *)"gpgme_get_protocol(ctx) -> gpgme_protocol_t"},
	 { "gpgme_set_sub_protocol", _wrap_gpgme_set_sub_protocol, METH_VARARGS, (char *)"gpgme_set_sub_protocol(ctx, proto) -> gpgme_error_t"},
	 { "gpgme_get_sub_protocol", _wrap_gpgme_get_sub_protocol, METH_VARARGS, (char *)"gpgme_get_sub_protocol(ctx) -> gpgme_protocol_t"},
	 { "gpgme_get_protocol_name", _wrap_gpgme_get_protocol_name, METH_VARARGS, (char *)"gpgme_get_protocol_name(proto) -> char const *"},
	 { "gpgme_set_armor", _wrap_gpgme_set_armor, METH_VARARGS, (char *)"gpgme_set_armor(ctx, yes)"},
	 { "gpgme_get_armor", _wrap_gpgme_get_armor, METH_VARARGS, (char *)"gpgme_get_armor(ctx) -> int"},
	 { "gpgme_set_textmode", _wrap_gpgme_set_textmode, METH_VARARGS, (char *)"gpgme_set_textmode(ctx, yes)"},
	 { "gpgme_get_textmode", _wrap_gpgme_get_textmode, METH_VARARGS, (char *)"gpgme_get_textmode(ctx) -> int"},
	 { "gpgme_set_offline", _wrap_gpgme_set_offline, METH_VARARGS, (char *)"gpgme_set_offline(ctx, yes)"},
	 { "gpgme_get_offline", _wrap_gpgme_get_offline, METH_VARARGS, (char *)"gpgme_get_offline(ctx) -> int"},
	 { "gpgme_set_include_certs", _wrap_gpgme_set_include_certs, METH_VARARGS, (char *)"gpgme_set_include_certs(ctx, nr_of_certs)"},
	 { "gpgme_get_include_certs", _wrap_gpgme_get_include_certs, METH_VARARGS, (char *)"gpgme_get_include_certs(ctx) -> int"},
	 { "gpgme_set_keylist_mode", _wrap_gpgme_set_keylist_mode, METH_VARARGS, (char *)"gpgme_set_keylist_mode(ctx, mode) -> gpgme_error_t"},
	 { "gpgme_get_keylist_mode", _wrap_gpgme_get_keylist_mode, METH_VARARGS, (char *)"gpgme_get_keylist_mode(ctx) -> gpgme_keylist_mode_t"},
	 { "gpgme_set_pinentry_mode", _wrap_gpgme_set_pinentry_mode, METH_VARARGS, (char *)"gpgme_set_pinentry_mode(ctx, mode) -> gpgme_error_t"},
	 { "gpgme_get_pinentry_mode", _wrap_gpgme_get_pinentry_mode, METH_VARARGS, (char *)"gpgme_get_pinentry_mode(ctx) -> gpgme_pinentry_mode_t"},
	 { "gpgme_set_passphrase_cb", _wrap_gpgme_set_passphrase_cb, METH_VARARGS, (char *)"gpgme_set_passphrase_cb(ctx, cb, hook_value)"},
	 { "gpgme_get_passphrase_cb", _wrap_gpgme_get_passphrase_cb, METH_VARARGS, (char *)"gpgme_get_passphrase_cb(ctx, cb, hook_value)"},
	 { "gpgme_set_progress_cb", _wrap_gpgme_set_progress_cb, METH_VARARGS, (char *)"gpgme_set_progress_cb(c, cb, hook_value)"},
	 { "gpgme_get_progress_cb", _wrap_gpgme_get_progress_cb, METH_VARARGS, (char *)"gpgme_get_progress_cb(ctx, cb, hook_value)"},
	 { "gpgme_set_status_cb", _wrap_gpgme_set_status_cb, METH_VARARGS, (char *)"gpgme_set_status_cb(c, cb, hook_value)"},
	 { "gpgme_get_status_cb", _wrap_gpgme_get_status_cb, METH_VARARGS, (char *)"gpgme_get_status_cb(ctx, cb, hook_value)"},
	 { "gpgme_set_locale", _wrap_gpgme_set_locale, METH_VARARGS, (char *)"gpgme_set_locale(ctx, category, value) -> gpgme_error_t"},
	 { "gpgme_ctx_get_engine_info", _wrap_gpgme_ctx_get_engine_info, METH_VARARGS, (char *)"gpgme_ctx_get_engine_info(ctx) -> _gpgme_engine_info"},
	 { "gpgme_ctx_set_engine_info", _wrap_gpgme_ctx_set_engine_info, METH_VARARGS, (char *)"gpgme_ctx_set_engine_info(ctx, proto, file_name, home_dir) -> gpgme_error_t"},
	 { "gpgme_signers_clear", _wrap_gpgme_signers_clear, METH_VARARGS, (char *)"gpgme_signers_clear(ctx)"},
	 { "gpgme_signers_add", _wrap_gpgme_signers_add, METH_VARARGS, (char *)"gpgme_signers_add(ctx, key) -> gpgme_error_t"},
	 { "gpgme_signers_count", _wrap_gpgme_signers_count, METH_VARARGS, (char *)"gpgme_signers_count(ctx) -> unsigned int"},
	 { "gpgme_signers_enum", _wrap_gpgme_signers_enum, METH_VARARGS, (char *)"gpgme_signers_enum(ctx, seq) -> _gpgme_key"},
	 { "gpgme_sig_notation_clear", _wrap_gpgme_sig_notation_clear, METH_VARARGS, (char *)"gpgme_sig_notation_clear(ctx)"},
	 { "gpgme_sig_notation_add", _wrap_gpgme_sig_notation_add, METH_VARARGS, (char *)"gpgme_sig_notation_add(ctx, name, value, flags) -> gpgme_error_t"},
	 { "gpgme_sig_notation_get", _wrap_gpgme_sig_notation_get, METH_VARARGS, (char *)"gpgme_sig_notation_get(ctx) -> _gpgme_sig_notation"},
	 { "gpgme_set_sender", _wrap_gpgme_set_sender, METH_VARARGS, (char *)"gpgme_set_sender(ctx, address) -> gpgme_error_t"},
	 { "gpgme_get_sender", _wrap_gpgme_get_sender, METH_VARARGS, (char *)"gpgme_get_sender(ctx) -> char const *"},
	 { "gpgme_io_event_done_data_err_set", _wrap_gpgme_io_event_done_data_err_set, METH_VARARGS, (char *)"gpgme_io_event_done_data_err_set(self, err)"},
	 { "gpgme_io_event_done_data_err_get", _wrap_gpgme_io_event_done_data_err_get, METH_VARARGS, (char *)"gpgme_io_event_done_data_err_get(self) -> gpgme_error_t"},
	 { "gpgme_io_event_done_data_op_err_set", _wrap_gpgme_io_event_done_data_op_err_set, METH_VARARGS, (char *)"gpgme_io_event_done_data_op_err_set(self, op_err)"},
	 { "gpgme_io_event_done_data_op_err_get", _wrap_gpgme_io_event_done_data_op_err_get, METH_VARARGS, (char *)"gpgme_io_event_done_data_op_err_get(self) -> gpgme_error_t"},
	 { "new_gpgme_io_event_done_data", _wrap_new_gpgme_io_event_done_data, METH_VARARGS, (char *)"new_gpgme_io_event_done_data() -> gpgme_io_event_done_data"},
	 { "delete_gpgme_io_event_done_data", _wrap_delete_gpgme_io_event_done_data, METH_VARARGS, (char *)"delete_gpgme_io_event_done_data(self)"},
	 { "gpgme_io_event_done_data_swigregister", gpgme_io_event_done_data_swigregister, METH_VARARGS, NULL},
	 { "gpgme_io_cbs_add_set", _wrap_gpgme_io_cbs_add_set, METH_VARARGS, (char *)"gpgme_io_cbs_add_set(self, add)"},
	 { "gpgme_io_cbs_add_get", _wrap_gpgme_io_cbs_add_get, METH_VARARGS, (char *)"gpgme_io_cbs_add_get(self) -> gpgme_register_io_cb_t"},
	 { "gpgme_io_cbs_add_priv_set", _wrap_gpgme_io_cbs_add_priv_set, METH_VARARGS, (char *)"gpgme_io_cbs_add_priv_set(self, add_priv)"},
	 { "gpgme_io_cbs_add_priv_get", _wrap_gpgme_io_cbs_add_priv_get, METH_VARARGS, (char *)"gpgme_io_cbs_add_priv_get(self) -> void *"},
	 { "gpgme_io_cbs_remove_set", _wrap_gpgme_io_cbs_remove_set, METH_VARARGS, (char *)"gpgme_io_cbs_remove_set(self, remove)"},
	 { "gpgme_io_cbs_remove_get", _wrap_gpgme_io_cbs_remove_get, METH_VARARGS, (char *)"gpgme_io_cbs_remove_get(self) -> gpgme_remove_io_cb_t"},
	 { "gpgme_io_cbs_event_set", _wrap_gpgme_io_cbs_event_set, METH_VARARGS, (char *)"gpgme_io_cbs_event_set(self, event)"},
	 { "gpgme_io_cbs_event_get", _wrap_gpgme_io_cbs_event_get, METH_VARARGS, (char *)"gpgme_io_cbs_event_get(self) -> gpgme_event_io_cb_t"},
	 { "gpgme_io_cbs_event_priv_set", _wrap_gpgme_io_cbs_event_priv_set, METH_VARARGS, (char *)"gpgme_io_cbs_event_priv_set(self, event_priv)"},
	 { "gpgme_io_cbs_event_priv_get", _wrap_gpgme_io_cbs_event_priv_get, METH_VARARGS, (char *)"gpgme_io_cbs_event_priv_get(self) -> void *"},
	 { "new_gpgme_io_cbs", _wrap_new_gpgme_io_cbs, METH_VARARGS, (char *)"new_gpgme_io_cbs() -> gpgme_io_cbs"},
	 { "delete_gpgme_io_cbs", _wrap_delete_gpgme_io_cbs, METH_VARARGS, (char *)"delete_gpgme_io_cbs(self)"},
	 { "gpgme_io_cbs_swigregister", gpgme_io_cbs_swigregister, METH_VARARGS, NULL},
	 { "gpgme_set_io_cbs", _wrap_gpgme_set_io_cbs, METH_VARARGS, (char *)"gpgme_set_io_cbs(ctx, io_cbs)"},
	 { "gpgme_get_io_cbs", _wrap_gpgme_get_io_cbs, METH_VARARGS, (char *)"gpgme_get_io_cbs(ctx, io_cbs)"},
	 { "gpgme_io_read", _wrap_gpgme_io_read, METH_VARARGS, (char *)"gpgme_io_read(fd, buffer, count) -> ssize_t"},
	 { "gpgme_io_write", _wrap_gpgme_io_write, METH_VARARGS, (char *)"gpgme_io_write(fd, buffer, count) -> ssize_t"},
	 { "gpgme_io_writen", _wrap_gpgme_io_writen, METH_VARARGS, (char *)"gpgme_io_writen(fd, buffer, count) -> int"},
	 { "gpgme_wait", _wrap_gpgme_wait, METH_VARARGS, (char *)"gpgme_wait(ctx, status, hang) -> gpgme_ctx_t"},
	 { "gpgme_wait_ext", _wrap_gpgme_wait_ext, METH_VARARGS, (char *)"gpgme_wait_ext(ctx, status, op_err, hang) -> gpgme_ctx_t"},
	 { "gpgme_cancel", _wrap_gpgme_cancel, METH_VARARGS, (char *)"gpgme_cancel(ctx) -> gpgme_error_t"},
	 { "gpgme_cancel_async", _wrap_gpgme_cancel_async, METH_VARARGS, (char *)"gpgme_cancel_async(ctx) -> gpgme_error_t"},
	 { "gpgme_data_cbs_read_set", _wrap_gpgme_data_cbs_read_set, METH_VARARGS, (char *)"gpgme_data_cbs_read_set(self, read)"},
	 { "gpgme_data_cbs_read_get", _wrap_gpgme_data_cbs_read_get, METH_VARARGS, (char *)"gpgme_data_cbs_read_get(self) -> gpgme_data_read_cb_t"},
	 { "gpgme_data_cbs_write_set", _wrap_gpgme_data_cbs_write_set, METH_VARARGS, (char *)"gpgme_data_cbs_write_set(self, write)"},
	 { "gpgme_data_cbs_write_get", _wrap_gpgme_data_cbs_write_get, METH_VARARGS, (char *)"gpgme_data_cbs_write_get(self) -> gpgme_data_write_cb_t"},
	 { "gpgme_data_cbs_seek_set", _wrap_gpgme_data_cbs_seek_set, METH_VARARGS, (char *)"gpgme_data_cbs_seek_set(self, seek)"},
	 { "gpgme_data_cbs_seek_get", _wrap_gpgme_data_cbs_seek_get, METH_VARARGS, (char *)"gpgme_data_cbs_seek_get(self) -> gpgme_data_seek_cb_t"},
	 { "gpgme_data_cbs_release_set", _wrap_gpgme_data_cbs_release_set, METH_VARARGS, (char *)"gpgme_data_cbs_release_set(self, release)"},
	 { "gpgme_data_cbs_release_get", _wrap_gpgme_data_cbs_release_get, METH_VARARGS, (char *)"gpgme_data_cbs_release_get(self) -> gpgme_data_release_cb_t"},
	 { "new_gpgme_data_cbs", _wrap_new_gpgme_data_cbs, METH_VARARGS, (char *)"new_gpgme_data_cbs() -> gpgme_data_cbs"},
	 { "delete_gpgme_data_cbs", _wrap_delete_gpgme_data_cbs, METH_VARARGS, (char *)"delete_gpgme_data_cbs(self)"},
	 { "gpgme_data_cbs_swigregister", gpgme_data_cbs_swigregister, METH_VARARGS, NULL},
	 { "gpgme_data_read", _wrap_gpgme_data_read, METH_VARARGS, (char *)"gpgme_data_read(dh, buffer) -> ssize_t"},
	 { "gpgme_data_write", _wrap_gpgme_data_write, METH_VARARGS, (char *)"gpgme_data_write(dh, buffer) -> ssize_t"},
	 { "gpgme_data_new", _wrap_gpgme_data_new, METH_VARARGS, (char *)"gpgme_data_new(r_dh) -> gpgme_error_t"},
	 { "gpgme_data_release", _wrap_gpgme_data_release, METH_VARARGS, (char *)"gpgme_data_release(dh)"},
	 { "gpgme_data_new_from_mem", _wrap_gpgme_data_new_from_mem, METH_VARARGS, (char *)"gpgme_data_new_from_mem(r_dh, buffer, size, copy) -> gpgme_error_t"},
	 { "gpgme_data_release_and_get_mem", _wrap_gpgme_data_release_and_get_mem, METH_VARARGS, (char *)"gpgme_data_release_and_get_mem(dh, r_len) -> char *"},
	 { "gpgme_free", _wrap_gpgme_free, METH_VARARGS, (char *)"gpgme_free(buffer)"},
	 { "gpgme_data_new_from_cbs", _wrap_gpgme_data_new_from_cbs, METH_VARARGS, (char *)"gpgme_data_new_from_cbs(dh, cbs, handle) -> gpgme_error_t"},
	 { "gpgme_data_new_from_fd", _wrap_gpgme_data_new_from_fd, METH_VARARGS, (char *)"gpgme_data_new_from_fd(dh, fd) -> gpgme_error_t"},
	 { "gpgme_data_new_from_stream", _wrap_gpgme_data_new_from_stream, METH_VARARGS, (char *)"gpgme_data_new_from_stream(dh, stream) -> gpgme_error_t"},
	 { "gpgme_data_new_from_estream", _wrap_gpgme_data_new_from_estream, METH_VARARGS, (char *)"gpgme_data_new_from_estream(r_dh, stream) -> gpgme_error_t"},
	 { "gpgme_data_get_encoding", _wrap_gpgme_data_get_encoding, METH_VARARGS, (char *)"gpgme_data_get_encoding(dh) -> gpgme_data_encoding_t"},
	 { "gpgme_data_set_encoding", _wrap_gpgme_data_set_encoding, METH_VARARGS, (char *)"gpgme_data_set_encoding(dh, enc) -> gpgme_error_t"},
	 { "gpgme_data_get_file_name", _wrap_gpgme_data_get_file_name, METH_VARARGS, (char *)"gpgme_data_get_file_name(dh) -> char *"},
	 { "gpgme_data_set_file_name", _wrap_gpgme_data_set_file_name, METH_VARARGS, (char *)"gpgme_data_set_file_name(dh, file_name) -> gpgme_error_t"},
	 { "gpgme_data_set_flag", _wrap_gpgme_data_set_flag, METH_VARARGS, (char *)"gpgme_data_set_flag(dh, name, value) -> gpg_error_t"},
	 { "gpgme_data_identify", _wrap_gpgme_data_identify, METH_VARARGS, (char *)"gpgme_data_identify(dh, reserved) -> gpgme_data_type_t"},
	 { "gpgme_data_new_from_file", _wrap_gpgme_data_new_from_file, METH_VARARGS, (char *)"gpgme_data_new_from_file(r_dh, fname, copy) -> gpgme_error_t"},
	 { "gpgme_data_new_from_filepart", _wrap_gpgme_data_new_from_filepart, METH_VARARGS, (char *)"gpgme_data_new_from_filepart(r_dh, fname, fp, offset, length) -> gpgme_error_t"},
	 { "gpgme_data_rewind", _wrap_gpgme_data_rewind, METH_VARARGS, (char *)"gpgme_data_rewind(dh) -> gpgme_error_t"},
	 { "gpgme_get_key", _wrap_gpgme_get_key, METH_VARARGS, (char *)"gpgme_get_key(ctx, fpr, r_key, secret) -> gpgme_error_t"},
	 { "gpgme_key_from_uid", _wrap_gpgme_key_from_uid, METH_VARARGS, (char *)"gpgme_key_from_uid(key, name) -> gpgme_error_t"},
	 { "gpgme_key_ref", _wrap_gpgme_key_ref, METH_VARARGS, (char *)"gpgme_key_ref(key)"},
	 { "gpgme_key_unref", _wrap_gpgme_key_unref, METH_VARARGS, (char *)"gpgme_key_unref(key)"},
	 { "gpgme_key_release", _wrap_gpgme_key_release, METH_VARARGS, (char *)"gpgme_key_release(key)"},
	 { "_gpgme_op_encrypt_result_invalid_recipients_set", _wrap__gpgme_op_encrypt_result_invalid_recipients_set, METH_VARARGS, (char *)"_gpgme_op_encrypt_result_invalid_recipients_set(self, invalid_recipients)"},
	 { "_gpgme_op_encrypt_result_invalid_recipients_get", _wrap__gpgme_op_encrypt_result_invalid_recipients_get, METH_VARARGS, (char *)"_gpgme_op_encrypt_result_invalid_recipients_get(self) -> _gpgme_invalid_key"},
	 { "new__gpgme_op_encrypt_result", _wrap_new__gpgme_op_encrypt_result, METH_VARARGS, (char *)"new__gpgme_op_encrypt_result() -> _gpgme_op_encrypt_result"},
	 { "delete__gpgme_op_encrypt_result", _wrap_delete__gpgme_op_encrypt_result, METH_VARARGS, (char *)"delete__gpgme_op_encrypt_result(self)"},
	 { "_gpgme_op_encrypt_result_swigregister", _gpgme_op_encrypt_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_encrypt_result", _wrap_gpgme_op_encrypt_result, METH_VARARGS, (char *)"gpgme_op_encrypt_result(ctx) -> _gpgme_op_encrypt_result"},
	 { "gpgme_op_encrypt_start", _wrap_gpgme_op_encrypt_start, METH_VARARGS, (char *)"gpgme_op_encrypt_start(ctx, recp, flags, plain, cipher) -> gpgme_error_t"},
	 { "gpgme_op_encrypt", _wrap_gpgme_op_encrypt, METH_VARARGS, (char *)"gpgme_op_encrypt(ctx, recp, flags, plain, cipher) -> gpgme_error_t"},
	 { "gpgme_op_encrypt_ext_start", _wrap_gpgme_op_encrypt_ext_start, METH_VARARGS, (char *)"gpgme_op_encrypt_ext_start(ctx, recp, recpstring, flags, plain, cipher) -> gpgme_error_t"},
	 { "gpgme_op_encrypt_ext", _wrap_gpgme_op_encrypt_ext, METH_VARARGS, (char *)"gpgme_op_encrypt_ext(ctx, recp, recpstring, flags, plain, cipher) -> gpgme_error_t"},
	 { "gpgme_op_encrypt_sign_start", _wrap_gpgme_op_encrypt_sign_start, METH_VARARGS, (char *)"gpgme_op_encrypt_sign_start(ctx, recp, flags, plain, cipher) -> gpgme_error_t"},
	 { "gpgme_op_encrypt_sign", _wrap_gpgme_op_encrypt_sign, METH_VARARGS, (char *)"gpgme_op_encrypt_sign(ctx, recp, flags, plain, cipher) -> gpgme_error_t"},
	 { "gpgme_op_encrypt_sign_ext_start", _wrap_gpgme_op_encrypt_sign_ext_start, METH_VARARGS, (char *)"gpgme_op_encrypt_sign_ext_start(ctx, recp, recpstring, flags, plain, cipher) -> gpgme_error_t"},
	 { "gpgme_op_encrypt_sign_ext", _wrap_gpgme_op_encrypt_sign_ext, METH_VARARGS, (char *)"gpgme_op_encrypt_sign_ext(ctx, recp, recpstring, flags, plain, cipher) -> gpgme_error_t"},
	 { "_gpgme_recipient_keyid_set", _wrap__gpgme_recipient_keyid_set, METH_VARARGS, (char *)"_gpgme_recipient_keyid_set(self, keyid)"},
	 { "_gpgme_recipient_keyid_get", _wrap__gpgme_recipient_keyid_get, METH_VARARGS, (char *)"_gpgme_recipient_keyid_get(self) -> char *"},
	 { "_gpgme_recipient__keyid_set", _wrap__gpgme_recipient__keyid_set, METH_VARARGS, (char *)"_gpgme_recipient__keyid_set(self, _keyid)"},
	 { "_gpgme_recipient__keyid_get", _wrap__gpgme_recipient__keyid_get, METH_VARARGS, (char *)"_gpgme_recipient__keyid_get(self) -> char [16+1]"},
	 { "_gpgme_recipient_pubkey_algo_set", _wrap__gpgme_recipient_pubkey_algo_set, METH_VARARGS, (char *)"_gpgme_recipient_pubkey_algo_set(self, pubkey_algo)"},
	 { "_gpgme_recipient_pubkey_algo_get", _wrap__gpgme_recipient_pubkey_algo_get, METH_VARARGS, (char *)"_gpgme_recipient_pubkey_algo_get(self) -> gpgme_pubkey_algo_t"},
	 { "_gpgme_recipient_status_set", _wrap__gpgme_recipient_status_set, METH_VARARGS, (char *)"_gpgme_recipient_status_set(self, status)"},
	 { "_gpgme_recipient_status_get", _wrap__gpgme_recipient_status_get, METH_VARARGS, (char *)"_gpgme_recipient_status_get(self) -> gpgme_error_t"},
	 { "new__gpgme_recipient", _wrap_new__gpgme_recipient, METH_VARARGS, (char *)"new__gpgme_recipient() -> _gpgme_recipient"},
	 { "delete__gpgme_recipient", _wrap_delete__gpgme_recipient, METH_VARARGS, (char *)"delete__gpgme_recipient(self)"},
	 { "_gpgme_recipient_swigregister", _gpgme_recipient_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_op_decrypt_result_unsupported_algorithm_set", _wrap__gpgme_op_decrypt_result_unsupported_algorithm_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_unsupported_algorithm_set(self, unsupported_algorithm)"},
	 { "_gpgme_op_decrypt_result_unsupported_algorithm_get", _wrap__gpgme_op_decrypt_result_unsupported_algorithm_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_unsupported_algorithm_get(self) -> char *"},
	 { "_gpgme_op_decrypt_result_wrong_key_usage_set", _wrap__gpgme_op_decrypt_result_wrong_key_usage_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_wrong_key_usage_set(self, wrong_key_usage)"},
	 { "_gpgme_op_decrypt_result_wrong_key_usage_get", _wrap__gpgme_op_decrypt_result_wrong_key_usage_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_wrong_key_usage_get(self) -> unsigned int"},
	 { "_gpgme_op_decrypt_result_is_de_vs_set", _wrap__gpgme_op_decrypt_result_is_de_vs_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_is_de_vs_set(self, is_de_vs)"},
	 { "_gpgme_op_decrypt_result_is_de_vs_get", _wrap__gpgme_op_decrypt_result_is_de_vs_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_is_de_vs_get(self) -> unsigned int"},
	 { "_gpgme_op_decrypt_result_is_mime_set", _wrap__gpgme_op_decrypt_result_is_mime_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_is_mime_set(self, is_mime)"},
	 { "_gpgme_op_decrypt_result_is_mime_get", _wrap__gpgme_op_decrypt_result_is_mime_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_is_mime_get(self) -> unsigned int"},
	 { "_gpgme_op_decrypt_result_legacy_cipher_nomdc_set", _wrap__gpgme_op_decrypt_result_legacy_cipher_nomdc_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_legacy_cipher_nomdc_set(self, legacy_cipher_nomdc)"},
	 { "_gpgme_op_decrypt_result_legacy_cipher_nomdc_get", _wrap__gpgme_op_decrypt_result_legacy_cipher_nomdc_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_legacy_cipher_nomdc_get(self) -> unsigned int"},
	 { "_gpgme_op_decrypt_result__unused_set", _wrap__gpgme_op_decrypt_result__unused_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result__unused_set(self, _unused)"},
	 { "_gpgme_op_decrypt_result__unused_get", _wrap__gpgme_op_decrypt_result__unused_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result__unused_get(self) -> int"},
	 { "_gpgme_op_decrypt_result_recipients_set", _wrap__gpgme_op_decrypt_result_recipients_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_recipients_set(self, recipients)"},
	 { "_gpgme_op_decrypt_result_recipients_get", _wrap__gpgme_op_decrypt_result_recipients_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_recipients_get(self) -> _gpgme_recipient"},
	 { "_gpgme_op_decrypt_result_file_name_set", _wrap__gpgme_op_decrypt_result_file_name_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_file_name_set(self, file_name)"},
	 { "_gpgme_op_decrypt_result_file_name_get", _wrap__gpgme_op_decrypt_result_file_name_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_file_name_get(self) -> char *"},
	 { "_gpgme_op_decrypt_result_session_key_set", _wrap__gpgme_op_decrypt_result_session_key_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_session_key_set(self, session_key)"},
	 { "_gpgme_op_decrypt_result_session_key_get", _wrap__gpgme_op_decrypt_result_session_key_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_session_key_get(self) -> char *"},
	 { "_gpgme_op_decrypt_result_symkey_algo_set", _wrap__gpgme_op_decrypt_result_symkey_algo_set, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_symkey_algo_set(self, symkey_algo)"},
	 { "_gpgme_op_decrypt_result_symkey_algo_get", _wrap__gpgme_op_decrypt_result_symkey_algo_get, METH_VARARGS, (char *)"_gpgme_op_decrypt_result_symkey_algo_get(self) -> char *"},
	 { "new__gpgme_op_decrypt_result", _wrap_new__gpgme_op_decrypt_result, METH_VARARGS, (char *)"new__gpgme_op_decrypt_result() -> _gpgme_op_decrypt_result"},
	 { "delete__gpgme_op_decrypt_result", _wrap_delete__gpgme_op_decrypt_result, METH_VARARGS, (char *)"delete__gpgme_op_decrypt_result(self)"},
	 { "_gpgme_op_decrypt_result_swigregister", _gpgme_op_decrypt_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_decrypt_result", _wrap_gpgme_op_decrypt_result, METH_VARARGS, (char *)"gpgme_op_decrypt_result(ctx) -> _gpgme_op_decrypt_result"},
	 { "gpgme_op_decrypt_start", _wrap_gpgme_op_decrypt_start, METH_VARARGS, (char *)"gpgme_op_decrypt_start(ctx, cipher, plain) -> gpgme_error_t"},
	 { "gpgme_op_decrypt", _wrap_gpgme_op_decrypt, METH_VARARGS, (char *)"gpgme_op_decrypt(ctx, cipher, plain) -> gpgme_error_t"},
	 { "gpgme_op_decrypt_verify_start", _wrap_gpgme_op_decrypt_verify_start, METH_VARARGS, (char *)"gpgme_op_decrypt_verify_start(ctx, cipher, plain) -> gpgme_error_t"},
	 { "gpgme_op_decrypt_verify", _wrap_gpgme_op_decrypt_verify, METH_VARARGS, (char *)"gpgme_op_decrypt_verify(ctx, cipher, plain) -> gpgme_error_t"},
	 { "gpgme_op_decrypt_ext_start", _wrap_gpgme_op_decrypt_ext_start, METH_VARARGS, (char *)"gpgme_op_decrypt_ext_start(ctx, flags, cipher, plain) -> gpgme_error_t"},
	 { "gpgme_op_decrypt_ext", _wrap_gpgme_op_decrypt_ext, METH_VARARGS, (char *)"gpgme_op_decrypt_ext(ctx, flags, cipher, plain) -> gpgme_error_t"},
	 { "_gpgme_new_signature_type_set", _wrap__gpgme_new_signature_type_set, METH_VARARGS, (char *)"_gpgme_new_signature_type_set(self, type)"},
	 { "_gpgme_new_signature_type_get", _wrap__gpgme_new_signature_type_get, METH_VARARGS, (char *)"_gpgme_new_signature_type_get(self) -> gpgme_sig_mode_t"},
	 { "_gpgme_new_signature_pubkey_algo_set", _wrap__gpgme_new_signature_pubkey_algo_set, METH_VARARGS, (char *)"_gpgme_new_signature_pubkey_algo_set(self, pubkey_algo)"},
	 { "_gpgme_new_signature_pubkey_algo_get", _wrap__gpgme_new_signature_pubkey_algo_get, METH_VARARGS, (char *)"_gpgme_new_signature_pubkey_algo_get(self) -> gpgme_pubkey_algo_t"},
	 { "_gpgme_new_signature_hash_algo_set", _wrap__gpgme_new_signature_hash_algo_set, METH_VARARGS, (char *)"_gpgme_new_signature_hash_algo_set(self, hash_algo)"},
	 { "_gpgme_new_signature_hash_algo_get", _wrap__gpgme_new_signature_hash_algo_get, METH_VARARGS, (char *)"_gpgme_new_signature_hash_algo_get(self) -> gpgme_hash_algo_t"},
	 { "_gpgme_new_signature__obsolete_class_set", _wrap__gpgme_new_signature__obsolete_class_set, METH_VARARGS, (char *)"_gpgme_new_signature__obsolete_class_set(self, _obsolete_class)"},
	 { "_gpgme_new_signature__obsolete_class_get", _wrap__gpgme_new_signature__obsolete_class_get, METH_VARARGS, (char *)"_gpgme_new_signature__obsolete_class_get(self) -> unsigned long"},
	 { "_gpgme_new_signature_timestamp_set", _wrap__gpgme_new_signature_timestamp_set, METH_VARARGS, (char *)"_gpgme_new_signature_timestamp_set(self, timestamp)"},
	 { "_gpgme_new_signature_timestamp_get", _wrap__gpgme_new_signature_timestamp_get, METH_VARARGS, (char *)"_gpgme_new_signature_timestamp_get(self) -> long"},
	 { "_gpgme_new_signature_fpr_set", _wrap__gpgme_new_signature_fpr_set, METH_VARARGS, (char *)"_gpgme_new_signature_fpr_set(self, fpr)"},
	 { "_gpgme_new_signature_fpr_get", _wrap__gpgme_new_signature_fpr_get, METH_VARARGS, (char *)"_gpgme_new_signature_fpr_get(self) -> char *"},
	 { "_gpgme_new_signature__obsolete_class_2_set", _wrap__gpgme_new_signature__obsolete_class_2_set, METH_VARARGS, (char *)"_gpgme_new_signature__obsolete_class_2_set(self, _obsolete_class_2)"},
	 { "_gpgme_new_signature__obsolete_class_2_get", _wrap__gpgme_new_signature__obsolete_class_2_get, METH_VARARGS, (char *)"_gpgme_new_signature__obsolete_class_2_get(self) -> unsigned int"},
	 { "_gpgme_new_signature_sig_class_set", _wrap__gpgme_new_signature_sig_class_set, METH_VARARGS, (char *)"_gpgme_new_signature_sig_class_set(self, sig_class)"},
	 { "_gpgme_new_signature_sig_class_get", _wrap__gpgme_new_signature_sig_class_get, METH_VARARGS, (char *)"_gpgme_new_signature_sig_class_get(self) -> unsigned int"},
	 { "new__gpgme_new_signature", _wrap_new__gpgme_new_signature, METH_VARARGS, (char *)"new__gpgme_new_signature() -> _gpgme_new_signature"},
	 { "delete__gpgme_new_signature", _wrap_delete__gpgme_new_signature, METH_VARARGS, (char *)"delete__gpgme_new_signature(self)"},
	 { "_gpgme_new_signature_swigregister", _gpgme_new_signature_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_op_sign_result_invalid_signers_set", _wrap__gpgme_op_sign_result_invalid_signers_set, METH_VARARGS, (char *)"_gpgme_op_sign_result_invalid_signers_set(self, invalid_signers)"},
	 { "_gpgme_op_sign_result_invalid_signers_get", _wrap__gpgme_op_sign_result_invalid_signers_get, METH_VARARGS, (char *)"_gpgme_op_sign_result_invalid_signers_get(self) -> _gpgme_invalid_key"},
	 { "_gpgme_op_sign_result_signatures_set", _wrap__gpgme_op_sign_result_signatures_set, METH_VARARGS, (char *)"_gpgme_op_sign_result_signatures_set(self, signatures)"},
	 { "_gpgme_op_sign_result_signatures_get", _wrap__gpgme_op_sign_result_signatures_get, METH_VARARGS, (char *)"_gpgme_op_sign_result_signatures_get(self) -> _gpgme_new_signature"},
	 { "new__gpgme_op_sign_result", _wrap_new__gpgme_op_sign_result, METH_VARARGS, (char *)"new__gpgme_op_sign_result() -> _gpgme_op_sign_result"},
	 { "delete__gpgme_op_sign_result", _wrap_delete__gpgme_op_sign_result, METH_VARARGS, (char *)"delete__gpgme_op_sign_result(self)"},
	 { "_gpgme_op_sign_result_swigregister", _gpgme_op_sign_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_sign_result", _wrap_gpgme_op_sign_result, METH_VARARGS, (char *)"gpgme_op_sign_result(ctx) -> _gpgme_op_sign_result"},
	 { "gpgme_op_sign_start", _wrap_gpgme_op_sign_start, METH_VARARGS, (char *)"gpgme_op_sign_start(ctx, plain, sig, mode) -> gpgme_error_t"},
	 { "gpgme_op_sign", _wrap_gpgme_op_sign, METH_VARARGS, (char *)"gpgme_op_sign(ctx, plain, sig, mode) -> gpgme_error_t"},
	 { "_gpgme_signature_summary_set", _wrap__gpgme_signature_summary_set, METH_VARARGS, (char *)"_gpgme_signature_summary_set(self, summary)"},
	 { "_gpgme_signature_summary_get", _wrap__gpgme_signature_summary_get, METH_VARARGS, (char *)"_gpgme_signature_summary_get(self) -> gpgme_sigsum_t"},
	 { "_gpgme_signature_fpr_set", _wrap__gpgme_signature_fpr_set, METH_VARARGS, (char *)"_gpgme_signature_fpr_set(self, fpr)"},
	 { "_gpgme_signature_fpr_get", _wrap__gpgme_signature_fpr_get, METH_VARARGS, (char *)"_gpgme_signature_fpr_get(self) -> char *"},
	 { "_gpgme_signature_status_set", _wrap__gpgme_signature_status_set, METH_VARARGS, (char *)"_gpgme_signature_status_set(self, status)"},
	 { "_gpgme_signature_status_get", _wrap__gpgme_signature_status_get, METH_VARARGS, (char *)"_gpgme_signature_status_get(self) -> gpgme_error_t"},
	 { "_gpgme_signature_notations_set", _wrap__gpgme_signature_notations_set, METH_VARARGS, (char *)"_gpgme_signature_notations_set(self, notations)"},
	 { "_gpgme_signature_notations_get", _wrap__gpgme_signature_notations_get, METH_VARARGS, (char *)"_gpgme_signature_notations_get(self) -> _gpgme_sig_notation"},
	 { "_gpgme_signature_timestamp_set", _wrap__gpgme_signature_timestamp_set, METH_VARARGS, (char *)"_gpgme_signature_timestamp_set(self, timestamp)"},
	 { "_gpgme_signature_timestamp_get", _wrap__gpgme_signature_timestamp_get, METH_VARARGS, (char *)"_gpgme_signature_timestamp_get(self) -> unsigned long"},
	 { "_gpgme_signature_exp_timestamp_set", _wrap__gpgme_signature_exp_timestamp_set, METH_VARARGS, (char *)"_gpgme_signature_exp_timestamp_set(self, exp_timestamp)"},
	 { "_gpgme_signature_exp_timestamp_get", _wrap__gpgme_signature_exp_timestamp_get, METH_VARARGS, (char *)"_gpgme_signature_exp_timestamp_get(self) -> unsigned long"},
	 { "_gpgme_signature_wrong_key_usage_set", _wrap__gpgme_signature_wrong_key_usage_set, METH_VARARGS, (char *)"_gpgme_signature_wrong_key_usage_set(self, wrong_key_usage)"},
	 { "_gpgme_signature_wrong_key_usage_get", _wrap__gpgme_signature_wrong_key_usage_get, METH_VARARGS, (char *)"_gpgme_signature_wrong_key_usage_get(self) -> unsigned int"},
	 { "_gpgme_signature_pka_trust_set", _wrap__gpgme_signature_pka_trust_set, METH_VARARGS, (char *)"_gpgme_signature_pka_trust_set(self, pka_trust)"},
	 { "_gpgme_signature_pka_trust_get", _wrap__gpgme_signature_pka_trust_get, METH_VARARGS, (char *)"_gpgme_signature_pka_trust_get(self) -> unsigned int"},
	 { "_gpgme_signature_chain_model_set", _wrap__gpgme_signature_chain_model_set, METH_VARARGS, (char *)"_gpgme_signature_chain_model_set(self, chain_model)"},
	 { "_gpgme_signature_chain_model_get", _wrap__gpgme_signature_chain_model_get, METH_VARARGS, (char *)"_gpgme_signature_chain_model_get(self) -> unsigned int"},
	 { "_gpgme_signature_is_de_vs_set", _wrap__gpgme_signature_is_de_vs_set, METH_VARARGS, (char *)"_gpgme_signature_is_de_vs_set(self, is_de_vs)"},
	 { "_gpgme_signature_is_de_vs_get", _wrap__gpgme_signature_is_de_vs_get, METH_VARARGS, (char *)"_gpgme_signature_is_de_vs_get(self) -> unsigned int"},
	 { "_gpgme_signature__unused_set", _wrap__gpgme_signature__unused_set, METH_VARARGS, (char *)"_gpgme_signature__unused_set(self, _unused)"},
	 { "_gpgme_signature__unused_get", _wrap__gpgme_signature__unused_get, METH_VARARGS, (char *)"_gpgme_signature__unused_get(self) -> int"},
	 { "_gpgme_signature_validity_set", _wrap__gpgme_signature_validity_set, METH_VARARGS, (char *)"_gpgme_signature_validity_set(self, validity)"},
	 { "_gpgme_signature_validity_get", _wrap__gpgme_signature_validity_get, METH_VARARGS, (char *)"_gpgme_signature_validity_get(self) -> gpgme_validity_t"},
	 { "_gpgme_signature_validity_reason_set", _wrap__gpgme_signature_validity_reason_set, METH_VARARGS, (char *)"_gpgme_signature_validity_reason_set(self, validity_reason)"},
	 { "_gpgme_signature_validity_reason_get", _wrap__gpgme_signature_validity_reason_get, METH_VARARGS, (char *)"_gpgme_signature_validity_reason_get(self) -> gpgme_error_t"},
	 { "_gpgme_signature_pubkey_algo_set", _wrap__gpgme_signature_pubkey_algo_set, METH_VARARGS, (char *)"_gpgme_signature_pubkey_algo_set(self, pubkey_algo)"},
	 { "_gpgme_signature_pubkey_algo_get", _wrap__gpgme_signature_pubkey_algo_get, METH_VARARGS, (char *)"_gpgme_signature_pubkey_algo_get(self) -> gpgme_pubkey_algo_t"},
	 { "_gpgme_signature_hash_algo_set", _wrap__gpgme_signature_hash_algo_set, METH_VARARGS, (char *)"_gpgme_signature_hash_algo_set(self, hash_algo)"},
	 { "_gpgme_signature_hash_algo_get", _wrap__gpgme_signature_hash_algo_get, METH_VARARGS, (char *)"_gpgme_signature_hash_algo_get(self) -> gpgme_hash_algo_t"},
	 { "_gpgme_signature_pka_address_set", _wrap__gpgme_signature_pka_address_set, METH_VARARGS, (char *)"_gpgme_signature_pka_address_set(self, pka_address)"},
	 { "_gpgme_signature_pka_address_get", _wrap__gpgme_signature_pka_address_get, METH_VARARGS, (char *)"_gpgme_signature_pka_address_get(self) -> char *"},
	 { "_gpgme_signature_key_set", _wrap__gpgme_signature_key_set, METH_VARARGS, (char *)"_gpgme_signature_key_set(self, key)"},
	 { "_gpgme_signature_key_get", _wrap__gpgme_signature_key_get, METH_VARARGS, (char *)"_gpgme_signature_key_get(self) -> _gpgme_key"},
	 { "new__gpgme_signature", _wrap_new__gpgme_signature, METH_VARARGS, (char *)"new__gpgme_signature() -> _gpgme_signature"},
	 { "delete__gpgme_signature", _wrap_delete__gpgme_signature, METH_VARARGS, (char *)"delete__gpgme_signature(self)"},
	 { "_gpgme_signature_swigregister", _gpgme_signature_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_op_verify_result_signatures_set", _wrap__gpgme_op_verify_result_signatures_set, METH_VARARGS, (char *)"_gpgme_op_verify_result_signatures_set(self, signatures)"},
	 { "_gpgme_op_verify_result_signatures_get", _wrap__gpgme_op_verify_result_signatures_get, METH_VARARGS, (char *)"_gpgme_op_verify_result_signatures_get(self) -> _gpgme_signature"},
	 { "_gpgme_op_verify_result_file_name_set", _wrap__gpgme_op_verify_result_file_name_set, METH_VARARGS, (char *)"_gpgme_op_verify_result_file_name_set(self, file_name)"},
	 { "_gpgme_op_verify_result_file_name_get", _wrap__gpgme_op_verify_result_file_name_get, METH_VARARGS, (char *)"_gpgme_op_verify_result_file_name_get(self) -> char *"},
	 { "_gpgme_op_verify_result_is_mime_set", _wrap__gpgme_op_verify_result_is_mime_set, METH_VARARGS, (char *)"_gpgme_op_verify_result_is_mime_set(self, is_mime)"},
	 { "_gpgme_op_verify_result_is_mime_get", _wrap__gpgme_op_verify_result_is_mime_get, METH_VARARGS, (char *)"_gpgme_op_verify_result_is_mime_get(self) -> unsigned int"},
	 { "_gpgme_op_verify_result__unused_set", _wrap__gpgme_op_verify_result__unused_set, METH_VARARGS, (char *)"_gpgme_op_verify_result__unused_set(self, _unused)"},
	 { "_gpgme_op_verify_result__unused_get", _wrap__gpgme_op_verify_result__unused_get, METH_VARARGS, (char *)"_gpgme_op_verify_result__unused_get(self) -> unsigned int"},
	 { "new__gpgme_op_verify_result", _wrap_new__gpgme_op_verify_result, METH_VARARGS, (char *)"new__gpgme_op_verify_result() -> _gpgme_op_verify_result"},
	 { "delete__gpgme_op_verify_result", _wrap_delete__gpgme_op_verify_result, METH_VARARGS, (char *)"delete__gpgme_op_verify_result(self)"},
	 { "_gpgme_op_verify_result_swigregister", _gpgme_op_verify_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_verify_result", _wrap_gpgme_op_verify_result, METH_VARARGS, (char *)"gpgme_op_verify_result(ctx) -> _gpgme_op_verify_result"},
	 { "gpgme_op_verify_start", _wrap_gpgme_op_verify_start, METH_VARARGS, (char *)"gpgme_op_verify_start(ctx, sig, signed_text, plaintext) -> gpgme_error_t"},
	 { "gpgme_op_verify", _wrap_gpgme_op_verify, METH_VARARGS, (char *)"gpgme_op_verify(ctx, sig, signed_text, plaintext) -> gpgme_error_t"},
	 { "_gpgme_import_status_fpr_set", _wrap__gpgme_import_status_fpr_set, METH_VARARGS, (char *)"_gpgme_import_status_fpr_set(self, fpr)"},
	 { "_gpgme_import_status_fpr_get", _wrap__gpgme_import_status_fpr_get, METH_VARARGS, (char *)"_gpgme_import_status_fpr_get(self) -> char *"},
	 { "_gpgme_import_status_result_set", _wrap__gpgme_import_status_result_set, METH_VARARGS, (char *)"_gpgme_import_status_result_set(self, result)"},
	 { "_gpgme_import_status_result_get", _wrap__gpgme_import_status_result_get, METH_VARARGS, (char *)"_gpgme_import_status_result_get(self) -> gpgme_error_t"},
	 { "_gpgme_import_status_status_set", _wrap__gpgme_import_status_status_set, METH_VARARGS, (char *)"_gpgme_import_status_status_set(self, status)"},
	 { "_gpgme_import_status_status_get", _wrap__gpgme_import_status_status_get, METH_VARARGS, (char *)"_gpgme_import_status_status_get(self) -> unsigned int"},
	 { "new__gpgme_import_status", _wrap_new__gpgme_import_status, METH_VARARGS, (char *)"new__gpgme_import_status() -> _gpgme_import_status"},
	 { "delete__gpgme_import_status", _wrap_delete__gpgme_import_status, METH_VARARGS, (char *)"delete__gpgme_import_status(self)"},
	 { "_gpgme_import_status_swigregister", _gpgme_import_status_swigregister, METH_VARARGS, NULL},
	 { "_gpgme_op_import_result_considered_set", _wrap__gpgme_op_import_result_considered_set, METH_VARARGS, (char *)"_gpgme_op_import_result_considered_set(self, considered)"},
	 { "_gpgme_op_import_result_considered_get", _wrap__gpgme_op_import_result_considered_get, METH_VARARGS, (char *)"_gpgme_op_import_result_considered_get(self) -> int"},
	 { "_gpgme_op_import_result_no_user_id_set", _wrap__gpgme_op_import_result_no_user_id_set, METH_VARARGS, (char *)"_gpgme_op_import_result_no_user_id_set(self, no_user_id)"},
	 { "_gpgme_op_import_result_no_user_id_get", _wrap__gpgme_op_import_result_no_user_id_get, METH_VARARGS, (char *)"_gpgme_op_import_result_no_user_id_get(self) -> int"},
	 { "_gpgme_op_import_result_imported_set", _wrap__gpgme_op_import_result_imported_set, METH_VARARGS, (char *)"_gpgme_op_import_result_imported_set(self, imported)"},
	 { "_gpgme_op_import_result_imported_get", _wrap__gpgme_op_import_result_imported_get, METH_VARARGS, (char *)"_gpgme_op_import_result_imported_get(self) -> int"},
	 { "_gpgme_op_import_result_imported_rsa_set", _wrap__gpgme_op_import_result_imported_rsa_set, METH_VARARGS, (char *)"_gpgme_op_import_result_imported_rsa_set(self, imported_rsa)"},
	 { "_gpgme_op_import_result_imported_rsa_get", _wrap__gpgme_op_import_result_imported_rsa_get, METH_VARARGS, (char *)"_gpgme_op_import_result_imported_rsa_get(self) -> int"},
	 { "_gpgme_op_import_result_unchanged_set", _wrap__gpgme_op_import_result_unchanged_set, METH_VARARGS, (char *)"_gpgme_op_import_result_unchanged_set(self, unchanged)"},
	 { "_gpgme_op_import_result_unchanged_get", _wrap__gpgme_op_import_result_unchanged_get, METH_VARARGS, (char *)"_gpgme_op_import_result_unchanged_get(self) -> int"},
	 { "_gpgme_op_import_result_new_user_ids_set", _wrap__gpgme_op_import_result_new_user_ids_set, METH_VARARGS, (char *)"_gpgme_op_import_result_new_user_ids_set(self, new_user_ids)"},
	 { "_gpgme_op_import_result_new_user_ids_get", _wrap__gpgme_op_import_result_new_user_ids_get, METH_VARARGS, (char *)"_gpgme_op_import_result_new_user_ids_get(self) -> int"},
	 { "_gpgme_op_import_result_new_sub_keys_set", _wrap__gpgme_op_import_result_new_sub_keys_set, METH_VARARGS, (char *)"_gpgme_op_import_result_new_sub_keys_set(self, new_sub_keys)"},
	 { "_gpgme_op_import_result_new_sub_keys_get", _wrap__gpgme_op_import_result_new_sub_keys_get, METH_VARARGS, (char *)"_gpgme_op_import_result_new_sub_keys_get(self) -> int"},
	 { "_gpgme_op_import_result_new_signatures_set", _wrap__gpgme_op_import_result_new_signatures_set, METH_VARARGS, (char *)"_gpgme_op_import_result_new_signatures_set(self, new_signatures)"},
	 { "_gpgme_op_import_result_new_signatures_get", _wrap__gpgme_op_import_result_new_signatures_get, METH_VARARGS, (char *)"_gpgme_op_import_result_new_signatures_get(self) -> int"},
	 { "_gpgme_op_import_result_new_revocations_set", _wrap__gpgme_op_import_result_new_revocations_set, METH_VARARGS, (char *)"_gpgme_op_import_result_new_revocations_set(self, new_revocations)"},
	 { "_gpgme_op_import_result_new_revocations_get", _wrap__gpgme_op_import_result_new_revocations_get, METH_VARARGS, (char *)"_gpgme_op_import_result_new_revocations_get(self) -> int"},
	 { "_gpgme_op_import_result_secret_read_set", _wrap__gpgme_op_import_result_secret_read_set, METH_VARARGS, (char *)"_gpgme_op_import_result_secret_read_set(self, secret_read)"},
	 { "_gpgme_op_import_result_secret_read_get", _wrap__gpgme_op_import_result_secret_read_get, METH_VARARGS, (char *)"_gpgme_op_import_result_secret_read_get(self) -> int"},
	 { "_gpgme_op_import_result_secret_imported_set", _wrap__gpgme_op_import_result_secret_imported_set, METH_VARARGS, (char *)"_gpgme_op_import_result_secret_imported_set(self, secret_imported)"},
	 { "_gpgme_op_import_result_secret_imported_get", _wrap__gpgme_op_import_result_secret_imported_get, METH_VARARGS, (char *)"_gpgme_op_import_result_secret_imported_get(self) -> int"},
	 { "_gpgme_op_import_result_secret_unchanged_set", _wrap__gpgme_op_import_result_secret_unchanged_set, METH_VARARGS, (char *)"_gpgme_op_import_result_secret_unchanged_set(self, secret_unchanged)"},
	 { "_gpgme_op_import_result_secret_unchanged_get", _wrap__gpgme_op_import_result_secret_unchanged_get, METH_VARARGS, (char *)"_gpgme_op_import_result_secret_unchanged_get(self) -> int"},
	 { "_gpgme_op_import_result_skipped_new_keys_set", _wrap__gpgme_op_import_result_skipped_new_keys_set, METH_VARARGS, (char *)"_gpgme_op_import_result_skipped_new_keys_set(self, skipped_new_keys)"},
	 { "_gpgme_op_import_result_skipped_new_keys_get", _wrap__gpgme_op_import_result_skipped_new_keys_get, METH_VARARGS, (char *)"_gpgme_op_import_result_skipped_new_keys_get(self) -> int"},
	 { "_gpgme_op_import_result_not_imported_set", _wrap__gpgme_op_import_result_not_imported_set, METH_VARARGS, (char *)"_gpgme_op_import_result_not_imported_set(self, not_imported)"},
	 { "_gpgme_op_import_result_not_imported_get", _wrap__gpgme_op_import_result_not_imported_get, METH_VARARGS, (char *)"_gpgme_op_import_result_not_imported_get(self) -> int"},
	 { "_gpgme_op_import_result_imports_set", _wrap__gpgme_op_import_result_imports_set, METH_VARARGS, (char *)"_gpgme_op_import_result_imports_set(self, imports)"},
	 { "_gpgme_op_import_result_imports_get", _wrap__gpgme_op_import_result_imports_get, METH_VARARGS, (char *)"_gpgme_op_import_result_imports_get(self) -> _gpgme_import_status"},
	 { "_gpgme_op_import_result_skipped_v3_keys_set", _wrap__gpgme_op_import_result_skipped_v3_keys_set, METH_VARARGS, (char *)"_gpgme_op_import_result_skipped_v3_keys_set(self, skipped_v3_keys)"},
	 { "_gpgme_op_import_result_skipped_v3_keys_get", _wrap__gpgme_op_import_result_skipped_v3_keys_get, METH_VARARGS, (char *)"_gpgme_op_import_result_skipped_v3_keys_get(self) -> int"},
	 { "new__gpgme_op_import_result", _wrap_new__gpgme_op_import_result, METH_VARARGS, (char *)"new__gpgme_op_import_result() -> _gpgme_op_import_result"},
	 { "delete__gpgme_op_import_result", _wrap_delete__gpgme_op_import_result, METH_VARARGS, (char *)"delete__gpgme_op_import_result(self)"},
	 { "_gpgme_op_import_result_swigregister", _gpgme_op_import_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_import_result", _wrap_gpgme_op_import_result, METH_VARARGS, (char *)"gpgme_op_import_result(ctx) -> _gpgme_op_import_result"},
	 { "gpgme_op_import_start", _wrap_gpgme_op_import_start, METH_VARARGS, (char *)"gpgme_op_import_start(ctx, keydata) -> gpgme_error_t"},
	 { "gpgme_op_import", _wrap_gpgme_op_import, METH_VARARGS, (char *)"gpgme_op_import(ctx, keydata) -> gpgme_error_t"},
	 { "gpgme_op_import_keys_start", _wrap_gpgme_op_import_keys_start, METH_VARARGS, (char *)"gpgme_op_import_keys_start(ctx, keys) -> gpgme_error_t"},
	 { "gpgme_op_import_keys", _wrap_gpgme_op_import_keys, METH_VARARGS, (char *)"gpgme_op_import_keys(ctx, keys) -> gpgme_error_t"},
	 { "gpgme_op_export_start", _wrap_gpgme_op_export_start, METH_VARARGS, (char *)"gpgme_op_export_start(ctx, pattern, mode, keydata) -> gpgme_error_t"},
	 { "gpgme_op_export", _wrap_gpgme_op_export, METH_VARARGS, (char *)"gpgme_op_export(ctx, pattern, mode, keydata) -> gpgme_error_t"},
	 { "gpgme_op_export_ext_start", _wrap_gpgme_op_export_ext_start, METH_VARARGS, (char *)"gpgme_op_export_ext_start(ctx, pattern, mode, keydata) -> gpgme_error_t"},
	 { "gpgme_op_export_ext", _wrap_gpgme_op_export_ext, METH_VARARGS, (char *)"gpgme_op_export_ext(ctx, pattern, mode, keydata) -> gpgme_error_t"},
	 { "gpgme_op_export_keys_start", _wrap_gpgme_op_export_keys_start, METH_VARARGS, (char *)"gpgme_op_export_keys_start(ctx, keys, mode, keydata) -> gpgme_error_t"},
	 { "gpgme_op_export_keys", _wrap_gpgme_op_export_keys, METH_VARARGS, (char *)"gpgme_op_export_keys(ctx, keys, mode, keydata) -> gpgme_error_t"},
	 { "_gpgme_op_genkey_result_primary_set", _wrap__gpgme_op_genkey_result_primary_set, METH_VARARGS, (char *)"_gpgme_op_genkey_result_primary_set(self, primary)"},
	 { "_gpgme_op_genkey_result_primary_get", _wrap__gpgme_op_genkey_result_primary_get, METH_VARARGS, (char *)"_gpgme_op_genkey_result_primary_get(self) -> unsigned int"},
	 { "_gpgme_op_genkey_result_sub_set", _wrap__gpgme_op_genkey_result_sub_set, METH_VARARGS, (char *)"_gpgme_op_genkey_result_sub_set(self, sub)"},
	 { "_gpgme_op_genkey_result_sub_get", _wrap__gpgme_op_genkey_result_sub_get, METH_VARARGS, (char *)"_gpgme_op_genkey_result_sub_get(self) -> unsigned int"},
	 { "_gpgme_op_genkey_result_uid_set", _wrap__gpgme_op_genkey_result_uid_set, METH_VARARGS, (char *)"_gpgme_op_genkey_result_uid_set(self, uid)"},
	 { "_gpgme_op_genkey_result_uid_get", _wrap__gpgme_op_genkey_result_uid_get, METH_VARARGS, (char *)"_gpgme_op_genkey_result_uid_get(self) -> unsigned int"},
	 { "_gpgme_op_genkey_result__unused_set", _wrap__gpgme_op_genkey_result__unused_set, METH_VARARGS, (char *)"_gpgme_op_genkey_result__unused_set(self, _unused)"},
	 { "_gpgme_op_genkey_result__unused_get", _wrap__gpgme_op_genkey_result__unused_get, METH_VARARGS, (char *)"_gpgme_op_genkey_result__unused_get(self) -> unsigned int"},
	 { "_gpgme_op_genkey_result_fpr_set", _wrap__gpgme_op_genkey_result_fpr_set, METH_VARARGS, (char *)"_gpgme_op_genkey_result_fpr_set(self, fpr)"},
	 { "_gpgme_op_genkey_result_fpr_get", _wrap__gpgme_op_genkey_result_fpr_get, METH_VARARGS, (char *)"_gpgme_op_genkey_result_fpr_get(self) -> char *"},
	 { "_gpgme_op_genkey_result_pubkey_set", _wrap__gpgme_op_genkey_result_pubkey_set, METH_VARARGS, (char *)"_gpgme_op_genkey_result_pubkey_set(self, pubkey)"},
	 { "_gpgme_op_genkey_result_pubkey_get", _wrap__gpgme_op_genkey_result_pubkey_get, METH_VARARGS, (char *)"_gpgme_op_genkey_result_pubkey_get(self) -> gpgme_data_t"},
	 { "_gpgme_op_genkey_result_seckey_set", _wrap__gpgme_op_genkey_result_seckey_set, METH_VARARGS, (char *)"_gpgme_op_genkey_result_seckey_set(self, seckey)"},
	 { "_gpgme_op_genkey_result_seckey_get", _wrap__gpgme_op_genkey_result_seckey_get, METH_VARARGS, (char *)"_gpgme_op_genkey_result_seckey_get(self) -> gpgme_data_t"},
	 { "new__gpgme_op_genkey_result", _wrap_new__gpgme_op_genkey_result, METH_VARARGS, (char *)"new__gpgme_op_genkey_result() -> _gpgme_op_genkey_result"},
	 { "delete__gpgme_op_genkey_result", _wrap_delete__gpgme_op_genkey_result, METH_VARARGS, (char *)"delete__gpgme_op_genkey_result(self)"},
	 { "_gpgme_op_genkey_result_swigregister", _gpgme_op_genkey_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_genkey_start", _wrap_gpgme_op_genkey_start, METH_VARARGS, (char *)"gpgme_op_genkey_start(ctx, parms, pubkey, seckey) -> gpgme_error_t"},
	 { "gpgme_op_genkey", _wrap_gpgme_op_genkey, METH_VARARGS, (char *)"gpgme_op_genkey(ctx, parms, pubkey, seckey) -> gpgme_error_t"},
	 { "gpgme_op_createkey_start", _wrap_gpgme_op_createkey_start, METH_VARARGS, (char *)"gpgme_op_createkey_start(ctx, userid, algo, reserved, expires, certkey, flags) -> gpgme_error_t"},
	 { "gpgme_op_createkey", _wrap_gpgme_op_createkey, METH_VARARGS, (char *)"gpgme_op_createkey(ctx, userid, algo, reserved, expires, certkey, flags) -> gpgme_error_t"},
	 { "gpgme_op_createsubkey_start", _wrap_gpgme_op_createsubkey_start, METH_VARARGS, (char *)"gpgme_op_createsubkey_start(ctx, key, algo, reserved, expires, flags) -> gpgme_error_t"},
	 { "gpgme_op_createsubkey", _wrap_gpgme_op_createsubkey, METH_VARARGS, (char *)"gpgme_op_createsubkey(ctx, key, algo, reserved, expires, flags) -> gpgme_error_t"},
	 { "gpgme_op_adduid_start", _wrap_gpgme_op_adduid_start, METH_VARARGS, (char *)"gpgme_op_adduid_start(ctx, key, userid, reserved) -> gpgme_error_t"},
	 { "gpgme_op_adduid", _wrap_gpgme_op_adduid, METH_VARARGS, (char *)"gpgme_op_adduid(ctx, key, userid, reserved) -> gpgme_error_t"},
	 { "gpgme_op_revuid_start", _wrap_gpgme_op_revuid_start, METH_VARARGS, (char *)"gpgme_op_revuid_start(ctx, key, userid, reserved) -> gpgme_error_t"},
	 { "gpgme_op_revuid", _wrap_gpgme_op_revuid, METH_VARARGS, (char *)"gpgme_op_revuid(ctx, key, userid, reserved) -> gpgme_error_t"},
	 { "gpgme_op_set_uid_flag_start", _wrap_gpgme_op_set_uid_flag_start, METH_VARARGS, (char *)"gpgme_op_set_uid_flag_start(ctx, key, userid, name, value) -> gpgme_error_t"},
	 { "gpgme_op_set_uid_flag", _wrap_gpgme_op_set_uid_flag, METH_VARARGS, (char *)"gpgme_op_set_uid_flag(ctx, key, userid, name, value) -> gpgme_error_t"},
	 { "gpgme_op_genkey_result", _wrap_gpgme_op_genkey_result, METH_VARARGS, (char *)"gpgme_op_genkey_result(ctx) -> _gpgme_op_genkey_result"},
	 { "gpgme_op_delete_start", _wrap_gpgme_op_delete_start, METH_VARARGS, (char *)"gpgme_op_delete_start(ctx, key, allow_secret) -> gpgme_error_t"},
	 { "gpgme_op_delete", _wrap_gpgme_op_delete, METH_VARARGS, (char *)"gpgme_op_delete(ctx, key, allow_secret) -> gpgme_error_t"},
	 { "gpgme_op_delete_ext_start", _wrap_gpgme_op_delete_ext_start, METH_VARARGS, (char *)"gpgme_op_delete_ext_start(ctx, key, flags) -> gpgme_error_t"},
	 { "gpgme_op_delete_ext", _wrap_gpgme_op_delete_ext, METH_VARARGS, (char *)"gpgme_op_delete_ext(ctx, key, flags) -> gpgme_error_t"},
	 { "gpgme_op_keysign_start", _wrap_gpgme_op_keysign_start, METH_VARARGS, (char *)"gpgme_op_keysign_start(ctx, key, userid, expires, flags) -> gpgme_error_t"},
	 { "gpgme_op_keysign", _wrap_gpgme_op_keysign, METH_VARARGS, (char *)"gpgme_op_keysign(ctx, key, userid, expires, flags) -> gpgme_error_t"},
	 { "gpgme_op_interact_start", _wrap_gpgme_op_interact_start, METH_VARARGS, (char *)"gpgme_op_interact_start(ctx, key, flags, fnc, out) -> gpgme_error_t"},
	 { "gpgme_op_interact", _wrap_gpgme_op_interact, METH_VARARGS, (char *)"gpgme_op_interact(ctx, key, flags, fnc, out) -> gpgme_error_t"},
	 { "gpgme_op_tofu_policy_start", _wrap_gpgme_op_tofu_policy_start, METH_VARARGS, (char *)"gpgme_op_tofu_policy_start(ctx, key, policy) -> gpgme_error_t"},
	 { "gpgme_op_tofu_policy", _wrap_gpgme_op_tofu_policy, METH_VARARGS, (char *)"gpgme_op_tofu_policy(ctx, key, policy) -> gpgme_error_t"},
	 { "_gpgme_op_keylist_result_truncated_set", _wrap__gpgme_op_keylist_result_truncated_set, METH_VARARGS, (char *)"_gpgme_op_keylist_result_truncated_set(self, truncated)"},
	 { "_gpgme_op_keylist_result_truncated_get", _wrap__gpgme_op_keylist_result_truncated_get, METH_VARARGS, (char *)"_gpgme_op_keylist_result_truncated_get(self) -> unsigned int"},
	 { "_gpgme_op_keylist_result__unused_set", _wrap__gpgme_op_keylist_result__unused_set, METH_VARARGS, (char *)"_gpgme_op_keylist_result__unused_set(self, _unused)"},
	 { "_gpgme_op_keylist_result__unused_get", _wrap__gpgme_op_keylist_result__unused_get, METH_VARARGS, (char *)"_gpgme_op_keylist_result__unused_get(self) -> unsigned int"},
	 { "new__gpgme_op_keylist_result", _wrap_new__gpgme_op_keylist_result, METH_VARARGS, (char *)"new__gpgme_op_keylist_result() -> _gpgme_op_keylist_result"},
	 { "delete__gpgme_op_keylist_result", _wrap_delete__gpgme_op_keylist_result, METH_VARARGS, (char *)"delete__gpgme_op_keylist_result(self)"},
	 { "_gpgme_op_keylist_result_swigregister", _gpgme_op_keylist_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_keylist_result", _wrap_gpgme_op_keylist_result, METH_VARARGS, (char *)"gpgme_op_keylist_result(ctx) -> _gpgme_op_keylist_result"},
	 { "gpgme_op_keylist_ext_start", _wrap_gpgme_op_keylist_ext_start, METH_VARARGS, (char *)"gpgme_op_keylist_ext_start(ctx, pattern, secret_only, reserved) -> gpgme_error_t"},
	 { "gpgme_op_keylist_from_data_start", _wrap_gpgme_op_keylist_from_data_start, METH_VARARGS, (char *)"gpgme_op_keylist_from_data_start(ctx, data, reserved) -> gpgme_error_t"},
	 { "gpgme_op_keylist_next", _wrap_gpgme_op_keylist_next, METH_VARARGS, (char *)"gpgme_op_keylist_next(ctx, r_key) -> gpgme_error_t"},
	 { "gpgme_op_keylist_end", _wrap_gpgme_op_keylist_end, METH_VARARGS, (char *)"gpgme_op_keylist_end(ctx) -> gpgme_error_t"},
	 { "gpgme_op_passwd_start", _wrap_gpgme_op_passwd_start, METH_VARARGS, (char *)"gpgme_op_passwd_start(ctx, key, flags) -> gpgme_error_t"},
	 { "gpgme_op_passwd", _wrap_gpgme_op_passwd, METH_VARARGS, (char *)"gpgme_op_passwd(ctx, key, flags) -> gpgme_error_t"},
	 { "_gpgme_trust_item__refs_set", _wrap__gpgme_trust_item__refs_set, METH_VARARGS, (char *)"_gpgme_trust_item__refs_set(self, _refs)"},
	 { "_gpgme_trust_item__refs_get", _wrap__gpgme_trust_item__refs_get, METH_VARARGS, (char *)"_gpgme_trust_item__refs_get(self) -> unsigned int"},
	 { "_gpgme_trust_item_keyid_set", _wrap__gpgme_trust_item_keyid_set, METH_VARARGS, (char *)"_gpgme_trust_item_keyid_set(self, keyid)"},
	 { "_gpgme_trust_item_keyid_get", _wrap__gpgme_trust_item_keyid_get, METH_VARARGS, (char *)"_gpgme_trust_item_keyid_get(self) -> char *"},
	 { "_gpgme_trust_item__keyid_set", _wrap__gpgme_trust_item__keyid_set, METH_VARARGS, (char *)"_gpgme_trust_item__keyid_set(self, _keyid)"},
	 { "_gpgme_trust_item__keyid_get", _wrap__gpgme_trust_item__keyid_get, METH_VARARGS, (char *)"_gpgme_trust_item__keyid_get(self) -> char [16+1]"},
	 { "_gpgme_trust_item_type_set", _wrap__gpgme_trust_item_type_set, METH_VARARGS, (char *)"_gpgme_trust_item_type_set(self, type)"},
	 { "_gpgme_trust_item_type_get", _wrap__gpgme_trust_item_type_get, METH_VARARGS, (char *)"_gpgme_trust_item_type_get(self) -> int"},
	 { "_gpgme_trust_item_level_set", _wrap__gpgme_trust_item_level_set, METH_VARARGS, (char *)"_gpgme_trust_item_level_set(self, level)"},
	 { "_gpgme_trust_item_level_get", _wrap__gpgme_trust_item_level_get, METH_VARARGS, (char *)"_gpgme_trust_item_level_get(self) -> int"},
	 { "_gpgme_trust_item_owner_trust_set", _wrap__gpgme_trust_item_owner_trust_set, METH_VARARGS, (char *)"_gpgme_trust_item_owner_trust_set(self, owner_trust)"},
	 { "_gpgme_trust_item_owner_trust_get", _wrap__gpgme_trust_item_owner_trust_get, METH_VARARGS, (char *)"_gpgme_trust_item_owner_trust_get(self) -> char *"},
	 { "_gpgme_trust_item__owner_trust_set", _wrap__gpgme_trust_item__owner_trust_set, METH_VARARGS, (char *)"_gpgme_trust_item__owner_trust_set(self, _owner_trust)"},
	 { "_gpgme_trust_item__owner_trust_get", _wrap__gpgme_trust_item__owner_trust_get, METH_VARARGS, (char *)"_gpgme_trust_item__owner_trust_get(self) -> char [2]"},
	 { "_gpgme_trust_item_validity_set", _wrap__gpgme_trust_item_validity_set, METH_VARARGS, (char *)"_gpgme_trust_item_validity_set(self, validity)"},
	 { "_gpgme_trust_item_validity_get", _wrap__gpgme_trust_item_validity_get, METH_VARARGS, (char *)"_gpgme_trust_item_validity_get(self) -> char *"},
	 { "_gpgme_trust_item__validity_set", _wrap__gpgme_trust_item__validity_set, METH_VARARGS, (char *)"_gpgme_trust_item__validity_set(self, _validity)"},
	 { "_gpgme_trust_item__validity_get", _wrap__gpgme_trust_item__validity_get, METH_VARARGS, (char *)"_gpgme_trust_item__validity_get(self) -> char [2]"},
	 { "_gpgme_trust_item_name_set", _wrap__gpgme_trust_item_name_set, METH_VARARGS, (char *)"_gpgme_trust_item_name_set(self, name)"},
	 { "_gpgme_trust_item_name_get", _wrap__gpgme_trust_item_name_get, METH_VARARGS, (char *)"_gpgme_trust_item_name_get(self) -> char *"},
	 { "new__gpgme_trust_item", _wrap_new__gpgme_trust_item, METH_VARARGS, (char *)"new__gpgme_trust_item() -> _gpgme_trust_item"},
	 { "delete__gpgme_trust_item", _wrap_delete__gpgme_trust_item, METH_VARARGS, (char *)"delete__gpgme_trust_item(self)"},
	 { "_gpgme_trust_item_swigregister", _gpgme_trust_item_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_trustlist_start", _wrap_gpgme_op_trustlist_start, METH_VARARGS, (char *)"gpgme_op_trustlist_start(ctx, pattern, max_level) -> gpgme_error_t"},
	 { "gpgme_op_trustlist_next", _wrap_gpgme_op_trustlist_next, METH_VARARGS, (char *)"gpgme_op_trustlist_next(ctx, r_item) -> gpgme_error_t"},
	 { "gpgme_op_trustlist_end", _wrap_gpgme_op_trustlist_end, METH_VARARGS, (char *)"gpgme_op_trustlist_end(ctx) -> gpgme_error_t"},
	 { "gpgme_trust_item_ref", _wrap_gpgme_trust_item_ref, METH_VARARGS, (char *)"gpgme_trust_item_ref(item)"},
	 { "gpgme_trust_item_unref", _wrap_gpgme_trust_item_unref, METH_VARARGS, (char *)"gpgme_trust_item_unref(item)"},
	 { "gpgme_op_getauditlog_start", _wrap_gpgme_op_getauditlog_start, METH_VARARGS, (char *)"gpgme_op_getauditlog_start(ctx, output, flags) -> gpgme_error_t"},
	 { "gpgme_op_getauditlog", _wrap_gpgme_op_getauditlog, METH_VARARGS, (char *)"gpgme_op_getauditlog(ctx, output, flags) -> gpgme_error_t"},
	 { "gpgme_op_spawn_start", _wrap_gpgme_op_spawn_start, METH_VARARGS, (char *)"gpgme_op_spawn_start(ctx, file, argv, datain, dataout, dataerr, flags) -> gpgme_error_t"},
	 { "gpgme_op_spawn", _wrap_gpgme_op_spawn, METH_VARARGS, (char *)"gpgme_op_spawn(ctx, file, argv, datain, dataout, dataerr, flags) -> gpgme_error_t"},
	 { "gpgme_op_assuan_transact_start", _wrap_gpgme_op_assuan_transact_start, METH_VARARGS, (char *)"gpgme_op_assuan_transact_start(ctx, command, data_cb, inq_cb, stat_cb) -> gpgme_error_t"},
	 { "gpgme_op_assuan_transact_ext", _wrap_gpgme_op_assuan_transact_ext, METH_VARARGS, (char *)"gpgme_op_assuan_transact_ext(ctx, command, data_cb, inq_cb, stat_cb, op_err) -> gpgme_error_t"},
	 { "_gpgme_op_vfs_mount_result_mount_dir_set", _wrap__gpgme_op_vfs_mount_result_mount_dir_set, METH_VARARGS, (char *)"_gpgme_op_vfs_mount_result_mount_dir_set(self, mount_dir)"},
	 { "_gpgme_op_vfs_mount_result_mount_dir_get", _wrap__gpgme_op_vfs_mount_result_mount_dir_get, METH_VARARGS, (char *)"_gpgme_op_vfs_mount_result_mount_dir_get(self) -> char *"},
	 { "new__gpgme_op_vfs_mount_result", _wrap_new__gpgme_op_vfs_mount_result, METH_VARARGS, (char *)"new__gpgme_op_vfs_mount_result() -> _gpgme_op_vfs_mount_result"},
	 { "delete__gpgme_op_vfs_mount_result", _wrap_delete__gpgme_op_vfs_mount_result, METH_VARARGS, (char *)"delete__gpgme_op_vfs_mount_result(self)"},
	 { "_gpgme_op_vfs_mount_result_swigregister", _gpgme_op_vfs_mount_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_vfs_mount_result", _wrap_gpgme_op_vfs_mount_result, METH_VARARGS, (char *)"gpgme_op_vfs_mount_result(ctx) -> _gpgme_op_vfs_mount_result"},
	 { "gpgme_op_vfs_mount", _wrap_gpgme_op_vfs_mount, METH_VARARGS, (char *)"gpgme_op_vfs_mount(ctx, container_file, mount_dir, flags, op_err) -> gpgme_error_t"},
	 { "gpgme_op_vfs_create", _wrap_gpgme_op_vfs_create, METH_VARARGS, (char *)"gpgme_op_vfs_create(ctx, recp, container_file, flags, op_err) -> gpgme_error_t"},
	 { "gpgme_conf_arg_no_arg_set", _wrap_gpgme_conf_arg_no_arg_set, METH_VARARGS, (char *)"gpgme_conf_arg_no_arg_set(self, no_arg)"},
	 { "gpgme_conf_arg_no_arg_get", _wrap_gpgme_conf_arg_no_arg_get, METH_VARARGS, (char *)"gpgme_conf_arg_no_arg_get(self) -> unsigned int"},
	 { "gpgme_conf_arg_value_get", _wrap_gpgme_conf_arg_value_get, METH_VARARGS, (char *)"gpgme_conf_arg_value_get(self) -> gpgme_conf_arg_value"},
	 { "new_gpgme_conf_arg", _wrap_new_gpgme_conf_arg, METH_VARARGS, (char *)"new_gpgme_conf_arg() -> gpgme_conf_arg"},
	 { "delete_gpgme_conf_arg", _wrap_delete_gpgme_conf_arg, METH_VARARGS, (char *)"delete_gpgme_conf_arg(self)"},
	 { "gpgme_conf_arg_swigregister", gpgme_conf_arg_swigregister, METH_VARARGS, NULL},
	 { "gpgme_conf_arg_value_count_set", _wrap_gpgme_conf_arg_value_count_set, METH_VARARGS, (char *)"gpgme_conf_arg_value_count_set(self, count)"},
	 { "gpgme_conf_arg_value_count_get", _wrap_gpgme_conf_arg_value_count_get, METH_VARARGS, (char *)"gpgme_conf_arg_value_count_get(self) -> unsigned int"},
	 { "gpgme_conf_arg_value_uint32_set", _wrap_gpgme_conf_arg_value_uint32_set, METH_VARARGS, (char *)"gpgme_conf_arg_value_uint32_set(self, uint32)"},
	 { "gpgme_conf_arg_value_uint32_get", _wrap_gpgme_conf_arg_value_uint32_get, METH_VARARGS, (char *)"gpgme_conf_arg_value_uint32_get(self) -> unsigned int"},
	 { "gpgme_conf_arg_value_int32_set", _wrap_gpgme_conf_arg_value_int32_set, METH_VARARGS, (char *)"gpgme_conf_arg_value_int32_set(self, int32)"},
	 { "gpgme_conf_arg_value_int32_get", _wrap_gpgme_conf_arg_value_int32_get, METH_VARARGS, (char *)"gpgme_conf_arg_value_int32_get(self) -> int"},
	 { "gpgme_conf_arg_value_string_set", _wrap_gpgme_conf_arg_value_string_set, METH_VARARGS, (char *)"gpgme_conf_arg_value_string_set(self, string)"},
	 { "gpgme_conf_arg_value_string_get", _wrap_gpgme_conf_arg_value_string_get, METH_VARARGS, (char *)"gpgme_conf_arg_value_string_get(self) -> char *"},
	 { "new_gpgme_conf_arg_value", _wrap_new_gpgme_conf_arg_value, METH_VARARGS, (char *)"new_gpgme_conf_arg_value() -> gpgme_conf_arg_value"},
	 { "delete_gpgme_conf_arg_value", _wrap_delete_gpgme_conf_arg_value, METH_VARARGS, (char *)"delete_gpgme_conf_arg_value(self)"},
	 { "gpgme_conf_arg_value_swigregister", gpgme_conf_arg_value_swigregister, METH_VARARGS, NULL},
	 { "gpgme_conf_opt_name_set", _wrap_gpgme_conf_opt_name_set, METH_VARARGS, (char *)"gpgme_conf_opt_name_set(self, name)"},
	 { "gpgme_conf_opt_name_get", _wrap_gpgme_conf_opt_name_get, METH_VARARGS, (char *)"gpgme_conf_opt_name_get(self) -> char *"},
	 { "gpgme_conf_opt_flags_set", _wrap_gpgme_conf_opt_flags_set, METH_VARARGS, (char *)"gpgme_conf_opt_flags_set(self, flags)"},
	 { "gpgme_conf_opt_flags_get", _wrap_gpgme_conf_opt_flags_get, METH_VARARGS, (char *)"gpgme_conf_opt_flags_get(self) -> unsigned int"},
	 { "gpgme_conf_opt_level_set", _wrap_gpgme_conf_opt_level_set, METH_VARARGS, (char *)"gpgme_conf_opt_level_set(self, level)"},
	 { "gpgme_conf_opt_level_get", _wrap_gpgme_conf_opt_level_get, METH_VARARGS, (char *)"gpgme_conf_opt_level_get(self) -> gpgme_conf_level_t"},
	 { "gpgme_conf_opt_description_set", _wrap_gpgme_conf_opt_description_set, METH_VARARGS, (char *)"gpgme_conf_opt_description_set(self, description)"},
	 { "gpgme_conf_opt_description_get", _wrap_gpgme_conf_opt_description_get, METH_VARARGS, (char *)"gpgme_conf_opt_description_get(self) -> char *"},
	 { "gpgme_conf_opt_type_set", _wrap_gpgme_conf_opt_type_set, METH_VARARGS, (char *)"gpgme_conf_opt_type_set(self, type)"},
	 { "gpgme_conf_opt_type_get", _wrap_gpgme_conf_opt_type_get, METH_VARARGS, (char *)"gpgme_conf_opt_type_get(self) -> gpgme_conf_type_t"},
	 { "gpgme_conf_opt_alt_type_set", _wrap_gpgme_conf_opt_alt_type_set, METH_VARARGS, (char *)"gpgme_conf_opt_alt_type_set(self, alt_type)"},
	 { "gpgme_conf_opt_alt_type_get", _wrap_gpgme_conf_opt_alt_type_get, METH_VARARGS, (char *)"gpgme_conf_opt_alt_type_get(self) -> gpgme_conf_type_t"},
	 { "gpgme_conf_opt_argname_set", _wrap_gpgme_conf_opt_argname_set, METH_VARARGS, (char *)"gpgme_conf_opt_argname_set(self, argname)"},
	 { "gpgme_conf_opt_argname_get", _wrap_gpgme_conf_opt_argname_get, METH_VARARGS, (char *)"gpgme_conf_opt_argname_get(self) -> char *"},
	 { "gpgme_conf_opt_default_value_set", _wrap_gpgme_conf_opt_default_value_set, METH_VARARGS, (char *)"gpgme_conf_opt_default_value_set(self, default_value)"},
	 { "gpgme_conf_opt_default_value_get", _wrap_gpgme_conf_opt_default_value_get, METH_VARARGS, (char *)"gpgme_conf_opt_default_value_get(self) -> gpgme_conf_arg"},
	 { "gpgme_conf_opt_default_description_set", _wrap_gpgme_conf_opt_default_description_set, METH_VARARGS, (char *)"gpgme_conf_opt_default_description_set(self, default_description)"},
	 { "gpgme_conf_opt_default_description_get", _wrap_gpgme_conf_opt_default_description_get, METH_VARARGS, (char *)"gpgme_conf_opt_default_description_get(self) -> char *"},
	 { "gpgme_conf_opt_no_arg_value_set", _wrap_gpgme_conf_opt_no_arg_value_set, METH_VARARGS, (char *)"gpgme_conf_opt_no_arg_value_set(self, no_arg_value)"},
	 { "gpgme_conf_opt_no_arg_value_get", _wrap_gpgme_conf_opt_no_arg_value_get, METH_VARARGS, (char *)"gpgme_conf_opt_no_arg_value_get(self) -> gpgme_conf_arg"},
	 { "gpgme_conf_opt_no_arg_description_set", _wrap_gpgme_conf_opt_no_arg_description_set, METH_VARARGS, (char *)"gpgme_conf_opt_no_arg_description_set(self, no_arg_description)"},
	 { "gpgme_conf_opt_no_arg_description_get", _wrap_gpgme_conf_opt_no_arg_description_get, METH_VARARGS, (char *)"gpgme_conf_opt_no_arg_description_get(self) -> char *"},
	 { "gpgme_conf_opt_value_set", _wrap_gpgme_conf_opt_value_set, METH_VARARGS, (char *)"gpgme_conf_opt_value_set(self, value)"},
	 { "gpgme_conf_opt_value_get", _wrap_gpgme_conf_opt_value_get, METH_VARARGS, (char *)"gpgme_conf_opt_value_get(self) -> gpgme_conf_arg"},
	 { "gpgme_conf_opt_change_value_set", _wrap_gpgme_conf_opt_change_value_set, METH_VARARGS, (char *)"gpgme_conf_opt_change_value_set(self, change_value)"},
	 { "gpgme_conf_opt_change_value_get", _wrap_gpgme_conf_opt_change_value_get, METH_VARARGS, (char *)"gpgme_conf_opt_change_value_get(self) -> int"},
	 { "gpgme_conf_opt_new_value_set", _wrap_gpgme_conf_opt_new_value_set, METH_VARARGS, (char *)"gpgme_conf_opt_new_value_set(self, new_value)"},
	 { "gpgme_conf_opt_new_value_get", _wrap_gpgme_conf_opt_new_value_get, METH_VARARGS, (char *)"gpgme_conf_opt_new_value_get(self) -> gpgme_conf_arg"},
	 { "gpgme_conf_opt_user_data_set", _wrap_gpgme_conf_opt_user_data_set, METH_VARARGS, (char *)"gpgme_conf_opt_user_data_set(self, user_data)"},
	 { "gpgme_conf_opt_user_data_get", _wrap_gpgme_conf_opt_user_data_get, METH_VARARGS, (char *)"gpgme_conf_opt_user_data_get(self) -> void *"},
	 { "new_gpgme_conf_opt", _wrap_new_gpgme_conf_opt, METH_VARARGS, (char *)"new_gpgme_conf_opt() -> gpgme_conf_opt"},
	 { "delete_gpgme_conf_opt", _wrap_delete_gpgme_conf_opt, METH_VARARGS, (char *)"delete_gpgme_conf_opt(self)"},
	 { "gpgme_conf_opt_swigregister", gpgme_conf_opt_swigregister, METH_VARARGS, NULL},
	 { "gpgme_conf_comp__last_opt_p_set", _wrap_gpgme_conf_comp__last_opt_p_set, METH_VARARGS, (char *)"gpgme_conf_comp__last_opt_p_set(self, _last_opt_p)"},
	 { "gpgme_conf_comp__last_opt_p_get", _wrap_gpgme_conf_comp__last_opt_p_get, METH_VARARGS, (char *)"gpgme_conf_comp__last_opt_p_get(self) -> gpgme_conf_opt_t *"},
	 { "gpgme_conf_comp_name_set", _wrap_gpgme_conf_comp_name_set, METH_VARARGS, (char *)"gpgme_conf_comp_name_set(self, name)"},
	 { "gpgme_conf_comp_name_get", _wrap_gpgme_conf_comp_name_get, METH_VARARGS, (char *)"gpgme_conf_comp_name_get(self) -> char *"},
	 { "gpgme_conf_comp_description_set", _wrap_gpgme_conf_comp_description_set, METH_VARARGS, (char *)"gpgme_conf_comp_description_set(self, description)"},
	 { "gpgme_conf_comp_description_get", _wrap_gpgme_conf_comp_description_get, METH_VARARGS, (char *)"gpgme_conf_comp_description_get(self) -> char *"},
	 { "gpgme_conf_comp_program_name_set", _wrap_gpgme_conf_comp_program_name_set, METH_VARARGS, (char *)"gpgme_conf_comp_program_name_set(self, program_name)"},
	 { "gpgme_conf_comp_program_name_get", _wrap_gpgme_conf_comp_program_name_get, METH_VARARGS, (char *)"gpgme_conf_comp_program_name_get(self) -> char *"},
	 { "gpgme_conf_comp_options_set", _wrap_gpgme_conf_comp_options_set, METH_VARARGS, (char *)"gpgme_conf_comp_options_set(self, options)"},
	 { "gpgme_conf_comp_options_get", _wrap_gpgme_conf_comp_options_get, METH_VARARGS, (char *)"gpgme_conf_comp_options_get(self) -> gpgme_conf_opt"},
	 { "new_gpgme_conf_comp", _wrap_new_gpgme_conf_comp, METH_VARARGS, (char *)"new_gpgme_conf_comp() -> gpgme_conf_comp"},
	 { "delete_gpgme_conf_comp", _wrap_delete_gpgme_conf_comp, METH_VARARGS, (char *)"delete_gpgme_conf_comp(self)"},
	 { "gpgme_conf_comp_swigregister", gpgme_conf_comp_swigregister, METH_VARARGS, NULL},
	 { "gpgme_conf_arg_new", _wrap_gpgme_conf_arg_new, METH_VARARGS, (char *)"gpgme_conf_arg_new(arg_p, type, value) -> gpgme_error_t"},
	 { "gpgme_conf_arg_release", _wrap_gpgme_conf_arg_release, METH_VARARGS, (char *)"gpgme_conf_arg_release(arg, type)"},
	 { "gpgme_conf_opt_change", _wrap_gpgme_conf_opt_change, METH_VARARGS, (char *)"gpgme_conf_opt_change(opt, reset, arg) -> gpgme_error_t"},
	 { "gpgme_conf_release", _wrap_gpgme_conf_release, METH_VARARGS, (char *)"gpgme_conf_release(conf)"},
	 { "gpgme_op_conf_load", _wrap_gpgme_op_conf_load, METH_VARARGS, (char *)"gpgme_op_conf_load(ctx, conf_p) -> gpgme_error_t"},
	 { "gpgme_op_conf_save", _wrap_gpgme_op_conf_save, METH_VARARGS, (char *)"gpgme_op_conf_save(ctx, comp) -> gpgme_error_t"},
	 { "gpgme_op_conf_dir", _wrap_gpgme_op_conf_dir, METH_VARARGS, (char *)"gpgme_op_conf_dir(ctx, what, result) -> gpgme_error_t"},
	 { "_gpgme_op_query_swdb_result_name_set", _wrap__gpgme_op_query_swdb_result_name_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_name_set(self, name)"},
	 { "_gpgme_op_query_swdb_result_name_get", _wrap__gpgme_op_query_swdb_result_name_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_name_get(self) -> char *"},
	 { "_gpgme_op_query_swdb_result_iversion_set", _wrap__gpgme_op_query_swdb_result_iversion_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_iversion_set(self, iversion)"},
	 { "_gpgme_op_query_swdb_result_iversion_get", _wrap__gpgme_op_query_swdb_result_iversion_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_iversion_get(self) -> char *"},
	 { "_gpgme_op_query_swdb_result_created_set", _wrap__gpgme_op_query_swdb_result_created_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_created_set(self, created)"},
	 { "_gpgme_op_query_swdb_result_created_get", _wrap__gpgme_op_query_swdb_result_created_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_created_get(self) -> unsigned long"},
	 { "_gpgme_op_query_swdb_result_retrieved_set", _wrap__gpgme_op_query_swdb_result_retrieved_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_retrieved_set(self, retrieved)"},
	 { "_gpgme_op_query_swdb_result_retrieved_get", _wrap__gpgme_op_query_swdb_result_retrieved_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_retrieved_get(self) -> unsigned long"},
	 { "_gpgme_op_query_swdb_result_warning_set", _wrap__gpgme_op_query_swdb_result_warning_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_warning_set(self, warning)"},
	 { "_gpgme_op_query_swdb_result_warning_get", _wrap__gpgme_op_query_swdb_result_warning_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_warning_get(self) -> unsigned int"},
	 { "_gpgme_op_query_swdb_result_update_set", _wrap__gpgme_op_query_swdb_result_update_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_update_set(self, update)"},
	 { "_gpgme_op_query_swdb_result_update_get", _wrap__gpgme_op_query_swdb_result_update_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_update_get(self) -> unsigned int"},
	 { "_gpgme_op_query_swdb_result_urgent_set", _wrap__gpgme_op_query_swdb_result_urgent_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_urgent_set(self, urgent)"},
	 { "_gpgme_op_query_swdb_result_urgent_get", _wrap__gpgme_op_query_swdb_result_urgent_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_urgent_get(self) -> unsigned int"},
	 { "_gpgme_op_query_swdb_result_noinfo_set", _wrap__gpgme_op_query_swdb_result_noinfo_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_noinfo_set(self, noinfo)"},
	 { "_gpgme_op_query_swdb_result_noinfo_get", _wrap__gpgme_op_query_swdb_result_noinfo_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_noinfo_get(self) -> unsigned int"},
	 { "_gpgme_op_query_swdb_result_unknown_set", _wrap__gpgme_op_query_swdb_result_unknown_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_unknown_set(self, unknown)"},
	 { "_gpgme_op_query_swdb_result_unknown_get", _wrap__gpgme_op_query_swdb_result_unknown_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_unknown_get(self) -> unsigned int"},
	 { "_gpgme_op_query_swdb_result_tooold_set", _wrap__gpgme_op_query_swdb_result_tooold_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_tooold_set(self, tooold)"},
	 { "_gpgme_op_query_swdb_result_tooold_get", _wrap__gpgme_op_query_swdb_result_tooold_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_tooold_get(self) -> unsigned int"},
	 { "_gpgme_op_query_swdb_result_error_set", _wrap__gpgme_op_query_swdb_result_error_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_error_set(self, error)"},
	 { "_gpgme_op_query_swdb_result_error_get", _wrap__gpgme_op_query_swdb_result_error_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_error_get(self) -> unsigned int"},
	 { "_gpgme_op_query_swdb_result__reserved_set", _wrap__gpgme_op_query_swdb_result__reserved_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result__reserved_set(self, _reserved)"},
	 { "_gpgme_op_query_swdb_result__reserved_get", _wrap__gpgme_op_query_swdb_result__reserved_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result__reserved_get(self) -> unsigned int"},
	 { "_gpgme_op_query_swdb_result_version_set", _wrap__gpgme_op_query_swdb_result_version_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_version_set(self, version)"},
	 { "_gpgme_op_query_swdb_result_version_get", _wrap__gpgme_op_query_swdb_result_version_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_version_get(self) -> char *"},
	 { "_gpgme_op_query_swdb_result_reldate_set", _wrap__gpgme_op_query_swdb_result_reldate_set, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_reldate_set(self, reldate)"},
	 { "_gpgme_op_query_swdb_result_reldate_get", _wrap__gpgme_op_query_swdb_result_reldate_get, METH_VARARGS, (char *)"_gpgme_op_query_swdb_result_reldate_get(self) -> unsigned long"},
	 { "new__gpgme_op_query_swdb_result", _wrap_new__gpgme_op_query_swdb_result, METH_VARARGS, (char *)"new__gpgme_op_query_swdb_result() -> _gpgme_op_query_swdb_result"},
	 { "delete__gpgme_op_query_swdb_result", _wrap_delete__gpgme_op_query_swdb_result, METH_VARARGS, (char *)"delete__gpgme_op_query_swdb_result(self)"},
	 { "_gpgme_op_query_swdb_result_swigregister", _gpgme_op_query_swdb_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_query_swdb", _wrap_gpgme_op_query_swdb, METH_VARARGS, (char *)"gpgme_op_query_swdb(ctx, name, iversion, reserved) -> gpgme_error_t"},
	 { "gpgme_op_query_swdb_result", _wrap_gpgme_op_query_swdb_result, METH_VARARGS, (char *)"gpgme_op_query_swdb_result(ctx) -> _gpgme_op_query_swdb_result"},
	 { "gpgme_set_global_flag", _wrap_gpgme_set_global_flag, METH_VARARGS, (char *)"gpgme_set_global_flag(name, value) -> int"},
	 { "gpgme_check_version", _wrap_gpgme_check_version, METH_VARARGS, (char *)"gpgme_check_version(req_version) -> char const *"},
	 { "gpgme_check_version_internal", _wrap_gpgme_check_version_internal, METH_VARARGS, (char *)"gpgme_check_version_internal(req_version, offset_sig_validity) -> char const *"},
	 { "gpgme_get_dirinfo", _wrap_gpgme_get_dirinfo, METH_VARARGS, (char *)"gpgme_get_dirinfo(what) -> char const *"},
	 { "gpgme_get_engine_info", _wrap_gpgme_get_engine_info, METH_VARARGS, (char *)"gpgme_get_engine_info(engine_info) -> gpgme_error_t"},
	 { "gpgme_set_engine_info", _wrap_gpgme_set_engine_info, METH_VARARGS, (char *)"gpgme_set_engine_info(proto, file_name, home_dir) -> gpgme_error_t"},
	 { "gpgme_engine_check_version", _wrap_gpgme_engine_check_version, METH_VARARGS, (char *)"gpgme_engine_check_version(proto) -> gpgme_error_t"},
	 { "gpgme_result_ref", _wrap_gpgme_result_ref, METH_VARARGS, (char *)"gpgme_result_ref(result)"},
	 { "gpgme_result_unref", _wrap_gpgme_result_unref, METH_VARARGS, (char *)"gpgme_result_unref(result)"},
	 { "gpgme_pubkey_algo_string", _wrap_gpgme_pubkey_algo_string, METH_VARARGS, (char *)"gpgme_pubkey_algo_string(subkey) -> char *"},
	 { "gpgme_pubkey_algo_name", _wrap_gpgme_pubkey_algo_name, METH_VARARGS, (char *)"gpgme_pubkey_algo_name(algo) -> char const *"},
	 { "gpgme_hash_algo_name", _wrap_gpgme_hash_algo_name, METH_VARARGS, (char *)"gpgme_hash_algo_name(algo) -> char const *"},
	 { "gpgme_addrspec_from_uid", _wrap_gpgme_addrspec_from_uid, METH_VARARGS, (char *)"gpgme_addrspec_from_uid(uid) -> char *"},
	 { "gpgme_op_edit_start", _wrap_gpgme_op_edit_start, METH_VARARGS, (char *)"gpgme_op_edit_start(ctx, key, fnc, fnc_value, out) -> gpgme_error_t"},
	 { "gpgme_op_edit", _wrap_gpgme_op_edit, METH_VARARGS, (char *)"gpgme_op_edit(ctx, key, fnc, fnc_value, out) -> gpgme_error_t"},
	 { "gpgme_op_card_edit_start", _wrap_gpgme_op_card_edit_start, METH_VARARGS, (char *)"gpgme_op_card_edit_start(ctx, key, fnc, fnc_value, out) -> gpgme_error_t"},
	 { "gpgme_op_card_edit", _wrap_gpgme_op_card_edit, METH_VARARGS, (char *)"gpgme_op_card_edit(ctx, key, fnc, fnc_value, out) -> gpgme_error_t"},
	 { "gpgme_get_sig_status", _wrap_gpgme_get_sig_status, METH_VARARGS, (char *)"gpgme_get_sig_status(ctx, idx, r_stat, r_created) -> char const *"},
	 { "gpgme_get_sig_ulong_attr", _wrap_gpgme_get_sig_ulong_attr, METH_VARARGS, (char *)"gpgme_get_sig_ulong_attr(c, idx, what, whatidx) -> unsigned long"},
	 { "gpgme_get_sig_string_attr", _wrap_gpgme_get_sig_string_attr, METH_VARARGS, (char *)"gpgme_get_sig_string_attr(c, idx, what, whatidx) -> char const *"},
	 { "gpgme_get_sig_key", _wrap_gpgme_get_sig_key, METH_VARARGS, (char *)"gpgme_get_sig_key(ctx, idx, r_key) -> gpgme_error_t"},
	 { "gpgme_data_new_with_read_cb", _wrap_gpgme_data_new_with_read_cb, METH_VARARGS, (char *)"gpgme_data_new_with_read_cb(r_dh, read_cb, read_cb_value) -> gpgme_error_t"},
	 { "gpgme_key_get_string_attr", _wrap_gpgme_key_get_string_attr, METH_VARARGS, (char *)"gpgme_key_get_string_attr(key, what, reserved, idx) -> char const *"},
	 { "gpgme_key_get_ulong_attr", _wrap_gpgme_key_get_ulong_attr, METH_VARARGS, (char *)"gpgme_key_get_ulong_attr(key, what, reserved, idx) -> unsigned long"},
	 { "gpgme_key_sig_get_string_attr", _wrap_gpgme_key_sig_get_string_attr, METH_VARARGS, (char *)"gpgme_key_sig_get_string_attr(key, uid_idx, what, reserved, idx) -> char const *"},
	 { "gpgme_key_sig_get_ulong_attr", _wrap_gpgme_key_sig_get_ulong_attr, METH_VARARGS, (char *)"gpgme_key_sig_get_ulong_attr(key, uid_idx, what, reserved, idx) -> unsigned long"},
	 { "gpgme_op_import_ext", _wrap_gpgme_op_import_ext, METH_VARARGS, (char *)"gpgme_op_import_ext(ctx, keydata, nr) -> gpgme_error_t"},
	 { "gpgme_trust_item_release", _wrap_gpgme_trust_item_release, METH_VARARGS, (char *)"gpgme_trust_item_release(item)"},
	 { "gpgme_trust_item_get_string_attr", _wrap_gpgme_trust_item_get_string_attr, METH_VARARGS, (char *)"gpgme_trust_item_get_string_attr(item, what, reserved, idx) -> char const *"},
	 { "gpgme_trust_item_get_int_attr", _wrap_gpgme_trust_item_get_int_attr, METH_VARARGS, (char *)"gpgme_trust_item_get_int_attr(item, what, reserved, idx) -> int"},
	 { "_gpgme_op_assuan_result_err_set", _wrap__gpgme_op_assuan_result_err_set, METH_VARARGS, (char *)"_gpgme_op_assuan_result_err_set(self, err)"},
	 { "_gpgme_op_assuan_result_err_get", _wrap__gpgme_op_assuan_result_err_get, METH_VARARGS, (char *)"_gpgme_op_assuan_result_err_get(self) -> gpgme_error_t"},
	 { "new__gpgme_op_assuan_result", _wrap_new__gpgme_op_assuan_result, METH_VARARGS, (char *)"new__gpgme_op_assuan_result() -> _gpgme_op_assuan_result"},
	 { "delete__gpgme_op_assuan_result", _wrap_delete__gpgme_op_assuan_result, METH_VARARGS, (char *)"delete__gpgme_op_assuan_result(self)"},
	 { "_gpgme_op_assuan_result_swigregister", _gpgme_op_assuan_result_swigregister, METH_VARARGS, NULL},
	 { "gpgme_op_assuan_result", _wrap_gpgme_op_assuan_result, METH_VARARGS, (char *)"gpgme_op_assuan_result(ctx) -> _gpgme_op_assuan_result"},
	 { "gpgme_op_assuan_transact", _wrap_gpgme_op_assuan_transact, METH_VARARGS, (char *)"gpgme_op_assuan_transact(ctx, command, data_cb, inq_cb, status_cb, status_cb_value) -> gpgme_error_t"},
	 { "new_gpgme_ctx_t_p", _wrap_new_gpgme_ctx_t_p, METH_VARARGS, (char *)"new_gpgme_ctx_t_p() -> gpgme_ctx_t *"},
	 { "copy_gpgme_ctx_t_p", _wrap_copy_gpgme_ctx_t_p, METH_VARARGS, (char *)"copy_gpgme_ctx_t_p(value) -> gpgme_ctx_t *"},
	 { "delete_gpgme_ctx_t_p", _wrap_delete_gpgme_ctx_t_p, METH_VARARGS, (char *)"delete_gpgme_ctx_t_p(obj)"},
	 { "gpgme_ctx_t_p_assign", _wrap_gpgme_ctx_t_p_assign, METH_VARARGS, (char *)"gpgme_ctx_t_p_assign(obj, value)"},
	 { "gpgme_ctx_t_p_value", _wrap_gpgme_ctx_t_p_value, METH_VARARGS, (char *)"gpgme_ctx_t_p_value(obj) -> gpgme_ctx_t"},
	 { "new_gpgme_data_t_p", _wrap_new_gpgme_data_t_p, METH_VARARGS, (char *)"new_gpgme_data_t_p() -> gpgme_data_t *"},
	 { "copy_gpgme_data_t_p", _wrap_copy_gpgme_data_t_p, METH_VARARGS, (char *)"copy_gpgme_data_t_p(value) -> gpgme_data_t *"},
	 { "delete_gpgme_data_t_p", _wrap_delete_gpgme_data_t_p, METH_VARARGS, (char *)"delete_gpgme_data_t_p(obj)"},
	 { "gpgme_data_t_p_assign", _wrap_gpgme_data_t_p_assign, METH_VARARGS, (char *)"gpgme_data_t_p_assign(obj, value)"},
	 { "gpgme_data_t_p_value", _wrap_gpgme_data_t_p_value, METH_VARARGS, (char *)"gpgme_data_t_p_value(obj) -> gpgme_data_t"},
	 { "new_gpgme_key_t_p", _wrap_new_gpgme_key_t_p, METH_VARARGS, (char *)"new_gpgme_key_t_p() -> gpgme_key_t *"},
	 { "copy_gpgme_key_t_p", _wrap_copy_gpgme_key_t_p, METH_VARARGS, (char *)"copy_gpgme_key_t_p(value) -> gpgme_key_t *"},
	 { "delete_gpgme_key_t_p", _wrap_delete_gpgme_key_t_p, METH_VARARGS, (char *)"delete_gpgme_key_t_p(obj)"},
	 { "gpgme_key_t_p_assign", _wrap_gpgme_key_t_p_assign, METH_VARARGS, (char *)"gpgme_key_t_p_assign(obj, value)"},
	 { "gpgme_key_t_p_value", _wrap_gpgme_key_t_p_value, METH_VARARGS, (char *)"gpgme_key_t_p_value(obj) -> _gpgme_key"},
	 { "new_gpgme_error_t_p", _wrap_new_gpgme_error_t_p, METH_VARARGS, (char *)"new_gpgme_error_t_p() -> gpgme_error_t *"},
	 { "copy_gpgme_error_t_p", _wrap_copy_gpgme_error_t_p, METH_VARARGS, (char *)"copy_gpgme_error_t_p(value) -> gpgme_error_t *"},
	 { "delete_gpgme_error_t_p", _wrap_delete_gpgme_error_t_p, METH_VARARGS, (char *)"delete_gpgme_error_t_p(obj)"},
	 { "gpgme_error_t_p_assign", _wrap_gpgme_error_t_p_assign, METH_VARARGS, (char *)"gpgme_error_t_p_assign(obj, value)"},
	 { "gpgme_error_t_p_value", _wrap_gpgme_error_t_p_value, METH_VARARGS, (char *)"gpgme_error_t_p_value(obj) -> gpgme_error_t"},
	 { "new_gpgme_trust_item_t_p", _wrap_new_gpgme_trust_item_t_p, METH_VARARGS, (char *)"new_gpgme_trust_item_t_p() -> gpgme_trust_item_t *"},
	 { "copy_gpgme_trust_item_t_p", _wrap_copy_gpgme_trust_item_t_p, METH_VARARGS, (char *)"copy_gpgme_trust_item_t_p(value) -> gpgme_trust_item_t *"},
	 { "delete_gpgme_trust_item_t_p", _wrap_delete_gpgme_trust_item_t_p, METH_VARARGS, (char *)"delete_gpgme_trust_item_t_p(obj)"},
	 { "gpgme_trust_item_t_p_assign", _wrap_gpgme_trust_item_t_p_assign, METH_VARARGS, (char *)"gpgme_trust_item_t_p_assign(obj, value)"},
	 { "gpgme_trust_item_t_p_value", _wrap_gpgme_trust_item_t_p_value, METH_VARARGS, (char *)"gpgme_trust_item_t_p_value(obj) -> _gpgme_trust_item"},
	 { "new_gpgme_engine_info_t_p", _wrap_new_gpgme_engine_info_t_p, METH_VARARGS, (char *)"new_gpgme_engine_info_t_p() -> gpgme_engine_info_t *"},
	 { "copy_gpgme_engine_info_t_p", _wrap_copy_gpgme_engine_info_t_p, METH_VARARGS, (char *)"copy_gpgme_engine_info_t_p(value) -> gpgme_engine_info_t *"},
	 { "delete_gpgme_engine_info_t_p", _wrap_delete_gpgme_engine_info_t_p, METH_VARARGS, (char *)"delete_gpgme_engine_info_t_p(obj)"},
	 { "gpgme_engine_info_t_p_assign", _wrap_gpgme_engine_info_t_p_assign, METH_VARARGS, (char *)"gpgme_engine_info_t_p_assign(obj, value)"},
	 { "gpgme_engine_info_t_p_value", _wrap_gpgme_engine_info_t_p_value, METH_VARARGS, (char *)"gpgme_engine_info_t_p_value(obj) -> _gpgme_engine_info"},
	 { "fdopen", _wrap_fdopen, METH_VARARGS, (char *)"fdopen(fildes, mode) -> FILE *"},
	 { "gpg_raise_callback_exception", _wrap_gpg_raise_callback_exception, METH_VARARGS, (char *)"gpg_raise_callback_exception(arg1) -> PyObject *"},
	 { "gpg_set_passphrase_cb", _wrap_gpg_set_passphrase_cb, METH_VARARGS, (char *)"gpg_set_passphrase_cb(arg1, cb) -> PyObject *"},
	 { "gpg_set_progress_cb", _wrap_gpg_set_progress_cb, METH_VARARGS, (char *)"gpg_set_progress_cb(arg1, cb) -> PyObject *"},
	 { "gpg_set_status_cb", _wrap_gpg_set_status_cb, METH_VARARGS, (char *)"gpg_set_status_cb(arg1, cb) -> PyObject *"},
	 { "gpg_data_new_from_cbs", _wrap_gpg_data_new_from_cbs, METH_VARARGS, (char *)"gpg_data_new_from_cbs(arg1, pycbs, r_data) -> PyObject *"},
	 { NULL, NULL, 0, NULL }
};


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

static swig_type_info _swigt__p_FILE = {"_p_FILE", "FILE *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_attr_t = {"_p__gpgme_attr_t", "enum _gpgme_attr_t *|_gpgme_attr_t *|gpgme_attr_t *|GpgmeAttr *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_engine_info = {"_p__gpgme_engine_info", "struct _gpgme_engine_info *|_gpgme_engine_info *|gpgme_engine_info_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_import_status = {"_p__gpgme_import_status", "gpgme_import_status_t|struct _gpgme_import_status *|_gpgme_import_status *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_invalid_key = {"_p__gpgme_invalid_key", "struct _gpgme_invalid_key *|_gpgme_invalid_key *|gpgme_invalid_key_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_key = {"_p__gpgme_key", "struct _gpgme_key *|_gpgme_key *|gpgme_key_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_key_sig = {"_p__gpgme_key_sig", "struct _gpgme_key_sig *|_gpgme_key_sig *|gpgme_key_sig_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_new_signature = {"_p__gpgme_new_signature", "struct _gpgme_new_signature *|_gpgme_new_signature *|gpgme_new_signature_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_assuan_result = {"_p__gpgme_op_assuan_result", "struct _gpgme_op_assuan_result *|_gpgme_op_assuan_result *|gpgme_assuan_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_decrypt_result = {"_p__gpgme_op_decrypt_result", "struct _gpgme_op_decrypt_result *|_gpgme_op_decrypt_result *|gpgme_decrypt_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_encrypt_result = {"_p__gpgme_op_encrypt_result", "struct _gpgme_op_encrypt_result *|_gpgme_op_encrypt_result *|gpgme_encrypt_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_genkey_result = {"_p__gpgme_op_genkey_result", "struct _gpgme_op_genkey_result *|_gpgme_op_genkey_result *|gpgme_genkey_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_import_result = {"_p__gpgme_op_import_result", "struct _gpgme_op_import_result *|_gpgme_op_import_result *|gpgme_import_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_keylist_result = {"_p__gpgme_op_keylist_result", "struct _gpgme_op_keylist_result *|_gpgme_op_keylist_result *|gpgme_keylist_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_query_swdb_result = {"_p__gpgme_op_query_swdb_result", "struct _gpgme_op_query_swdb_result *|_gpgme_op_query_swdb_result *|gpgme_query_swdb_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_sign_result = {"_p__gpgme_op_sign_result", "struct _gpgme_op_sign_result *|_gpgme_op_sign_result *|gpgme_sign_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_verify_result = {"_p__gpgme_op_verify_result", "struct _gpgme_op_verify_result *|_gpgme_op_verify_result *|gpgme_verify_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_op_vfs_mount_result = {"_p__gpgme_op_vfs_mount_result", "struct _gpgme_op_vfs_mount_result *|_gpgme_op_vfs_mount_result *|gpgme_vfs_mount_result_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_recipient = {"_p__gpgme_recipient", "gpgme_recipient_t|struct _gpgme_recipient *|_gpgme_recipient *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_sig_notation = {"_p__gpgme_sig_notation", "struct _gpgme_sig_notation *|_gpgme_sig_notation *|gpgme_sig_notation_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_sig_stat_t = {"_p__gpgme_sig_stat_t", "GpgmeSigStat *|enum _gpgme_sig_stat_t *|_gpgme_sig_stat_t *|gpgme_sig_stat_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_signature = {"_p__gpgme_signature", "struct _gpgme_signature *|_gpgme_signature *|gpgme_signature_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_subkey = {"_p__gpgme_subkey", "struct _gpgme_subkey *|_gpgme_subkey *|gpgme_subkey_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_tofu_info = {"_p__gpgme_tofu_info", "struct _gpgme_tofu_info *|_gpgme_tofu_info *|gpgme_tofu_info_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_trust_item = {"_p__gpgme_trust_item", "gpgme_trust_item_t|struct _gpgme_trust_item *|_gpgme_trust_item *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gpgme_user_id = {"_p__gpgme_user_id", "struct _gpgme_user_id *|_gpgme_user_id *|gpgme_user_id_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_a___p__gpgme_key = {"_p_a___p__gpgme_key", "gpgme_key_t (*)[]|struct _gpgme_key *(*)[]", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void__void = {"_p_f_p_void__void", "gpgme_remove_io_cb_t|void (*)(void *)|gpgme_data_release_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_enum_gpgme_event_io_t_p_void__void = {"_p_f_p_void_enum_gpgme_event_io_t_p_void__void", "gpgme_event_io_cb_t|void (*)(void *,enum gpgme_event_io_t,void *)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t = {"_p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t", "gpgme_edit_cb_t|gpg_error_t (*)(void *,enum gpgme_status_code_t,char const *,int)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t = {"_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t", "gpg_error_t (*)(void *,int,int,gpg_error_t (*)(void *,int),void *,void **)|gpgme_register_io_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_off_t_int__off_t = {"_p_f_p_void_off_t_int__off_t", "off_t (*)(void *,off_t,int)|gpgme_data_seek_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_char_size_t_p_size_t__int = {"_p_f_p_void_p_char_size_t_p_size_t__int", "int (*)(void *,char *,size_t,size_t *)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_q_const__char_int_int_int__void = {"_p_f_p_void_p_q_const__char_int_int_int__void", "void (*)(void *,char const *,int,int,int)|gpgme_progress_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t = {"_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t", "gpg_error_t (*)(void *,char const *,char const *)|gpgme_status_cb_t|gpgme_assuan_status_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_q_const__char_p_q_const__char_int__gpg_error_t = {"_p_f_p_void_p_q_const__char_p_q_const__char_int__gpg_error_t", "gpgme_interact_cb_t|gpg_error_t (*)(void *,char const *,char const *,int)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t = {"_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t", "gpg_error_t (*)(void *,char const *,char const *,int,int)|gpgme_passphrase_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_q_const__char_p_q_const__char_p_p_struct_gpgme_data__gpg_error_t = {"_p_f_p_void_p_q_const__char_p_q_const__char_p_p_struct_gpgme_data__gpg_error_t", "gpg_error_t (*)(void *,char const *,char const *,struct gpgme_data **)|gpgme_assuan_inquire_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_q_const__void_size_t__gpg_error_t = {"_p_f_p_void_p_q_const__void_size_t__gpg_error_t", "gpg_error_t (*)(void *,void const *,size_t)|gpgme_assuan_data_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_q_const__void_size_t__ssize_t = {"_p_f_p_void_p_q_const__void_size_t__ssize_t", "ssize_t (*)(void *,void const *,size_t)|gpgme_data_write_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_void_p_void_size_t__ssize_t = {"_p_f_p_void_p_void_size_t__ssize_t", "ssize_t (*)(void *,void *,size_t)|gpgme_data_read_cb_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpg_err_code_t = {"_p_gpg_err_code_t", "gpg_err_code_t *|gpgme_err_code_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpg_err_source_t = {"_p_gpg_err_source_t", "gpg_err_source_t *|gpgme_err_source_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpg_error_t = {"_p_gpg_error_t", "GpgmeError *|gpg_error_t *|gpgme_error_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_conf_arg = {"_p_gpgme_conf_arg", "struct gpgme_conf_arg *|gpgme_conf_arg *|gpgme_conf_arg_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_conf_arg_value = {"_p_gpgme_conf_arg_value", "gpgme_conf_arg_value *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_conf_comp = {"_p_gpgme_conf_comp", "struct gpgme_conf_comp *|gpgme_conf_comp *|gpgme_conf_comp_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_conf_level_t = {"_p_gpgme_conf_level_t", "enum gpgme_conf_level_t *|gpgme_conf_level_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_conf_opt = {"_p_gpgme_conf_opt", "gpgme_conf_opt_t|struct gpgme_conf_opt *|gpgme_conf_opt *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_conf_type_t = {"_p_gpgme_conf_type_t", "enum gpgme_conf_type_t *|gpgme_conf_type_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_context = {"_p_gpgme_context", "gpgme_ctx_t|struct gpgme_context *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_data = {"_p_gpgme_data", "struct gpgme_data *|gpgme_data_t", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_data_cbs = {"_p_gpgme_data_cbs", "gpgme_data_cbs_t|struct gpgme_data_cbs *|gpgme_data_cbs *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_data_encoding_t = {"_p_gpgme_data_encoding_t", "GpgmeDataEncoding *|enum gpgme_data_encoding_t *|gpgme_data_encoding_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_data_type_t = {"_p_gpgme_data_type_t", "enum gpgme_data_type_t *|gpgme_data_type_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_decrypt_flags_t = {"_p_gpgme_decrypt_flags_t", "enum gpgme_decrypt_flags_t *|gpgme_decrypt_flags_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_encrypt_flags_t = {"_p_gpgme_encrypt_flags_t", "enum gpgme_encrypt_flags_t *|gpgme_encrypt_flags_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_event_io_t = {"_p_gpgme_event_io_t", "enum gpgme_event_io_t *|gpgme_event_io_t *|GpgmeEventIO *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_hash_algo_t = {"_p_gpgme_hash_algo_t", "enum gpgme_hash_algo_t *|gpgme_hash_algo_t *|GpgmeHashAlgo *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_io_cbs = {"_p_gpgme_io_cbs", "gpgme_io_cbs_t|struct gpgme_io_cbs *|gpgme_io_cbs *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_io_event_done_data = {"_p_gpgme_io_event_done_data", "struct gpgme_io_event_done_data *|gpgme_io_event_done_data *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_keyorg_t = {"_p_gpgme_keyorg_t", "enum gpgme_keyorg_t *|gpgme_keyorg_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_pinentry_mode_t = {"_p_gpgme_pinentry_mode_t", "enum gpgme_pinentry_mode_t *|gpgme_pinentry_mode_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_protocol_t = {"_p_gpgme_protocol_t", "enum gpgme_protocol_t *|gpgme_protocol_t *|GpgmeProtocol *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_pubkey_algo_t = {"_p_gpgme_pubkey_algo_t", "enum gpgme_pubkey_algo_t *|gpgme_pubkey_algo_t *|GpgmePubKeyAlgo *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_sig_mode_t = {"_p_gpgme_sig_mode_t", "GpgmeSigMode *|enum gpgme_sig_mode_t *|gpgme_sig_mode_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_sigsum_t = {"_p_gpgme_sigsum_t", "enum gpgme_sigsum_t *|gpgme_sigsum_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_status_code_t = {"_p_gpgme_status_code_t", "enum gpgme_status_code_t *|gpgme_status_code_t *|GpgmeStatusCode *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_tofu_policy_t = {"_p_gpgme_tofu_policy_t", "enum gpgme_tofu_policy_t *|gpgme_tofu_policy_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgme_validity_t = {"_p_gpgme_validity_t", "GpgmeValidity *|enum gpgme_validity_t *|gpgme_validity_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gpgrt_stream_t = {"_p_gpgrt_stream_t", "gpgrt_stream_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_int = {"_p_int", "int *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_off_t = {"_p_off_t", "off_t *|gpgme_off_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_engine_info = {"_p_p__gpgme_engine_info", "GpgmeEngineInfo *|struct _gpgme_engine_info **|gpgme_engine_info_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_import_status = {"_p_p__gpgme_import_status", "struct _gpgme_import_status **|GpgmeImportStatus *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_key = {"_p_p__gpgme_key", "struct _gpgme_key **|GpgmeKey *|gpgme_key_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_key_sig = {"_p_p__gpgme_key_sig", "struct _gpgme_key_sig **|GpgmeKeySig *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_op_encrypt_result = {"_p_p__gpgme_op_encrypt_result", "GpgmeEncryptResult *|struct _gpgme_op_encrypt_result **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_op_genkey_result = {"_p_p__gpgme_op_genkey_result", "GpgmeGenKeyResult *|struct _gpgme_op_genkey_result **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_op_import_result = {"_p_p__gpgme_op_import_result", "GpgmeImportResult *|struct _gpgme_op_import_result **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_op_verify_result = {"_p_p__gpgme_op_verify_result", "GpgmeVerifyResult *|struct _gpgme_op_verify_result **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_sig_notation = {"_p_p__gpgme_sig_notation", "struct _gpgme_sig_notation **|GpgmeSigNotation *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_signature = {"_p_p__gpgme_signature", "GpgmeSignature *|struct _gpgme_signature **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_subkey = {"_p_p__gpgme_subkey", "GpgmeSubkey *|struct _gpgme_subkey **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_trust_item = {"_p_p__gpgme_trust_item", "struct _gpgme_trust_item **|GpgmeTrustItem *|gpgme_trust_item_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p__gpgme_user_id = {"_p_p__gpgme_user_id", "struct _gpgme_user_id **|GpgmeUserID *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_char = {"_p_p_char", "char **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void__void = {"_p_p_f_p_void__void", "GpgmeDataReleaseCb *|void (**)(void *)|GpgmeRemoveIOCb *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_enum_gpgme_event_io_t_p_void__void = {"_p_p_f_p_void_enum_gpgme_event_io_t_p_void__void", "GpgmeEventIOCb *|void (**)(void *,enum gpgme_event_io_t,void *)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_int__gpg_error_t = {"_p_p_f_p_void_int__gpg_error_t", "gpg_error_t (**)(void *,int)|GpgmeIOCb *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t = {"_p_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t", "gpg_error_t (**)(void *,int,int,gpg_error_t (*)(void *,int),void *,void **)|GpgmeRegisterIOCb *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_off_t_int__off_t = {"_p_p_f_p_void_off_t_int__off_t", "off_t (**)(void *,off_t,int)|GpgmeDataSeekCb *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_p_q_const__char_int_int_int__void = {"_p_p_f_p_void_p_q_const__char_int_int_int__void", "GpgmeProgressCb *|void (**)(void *,char const *,int,int,int)|gpgme_progress_cb_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t = {"_p_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t", "gpg_error_t (**)(void *,char const *,char const *)|gpgme_status_cb_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t = {"_p_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t", "GpgmePassphraseCb *|gpg_error_t (**)(void *,char const *,char const *,int,int)|gpgme_passphrase_cb_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_p_q_const__void_size_t__ssize_t = {"_p_p_f_p_void_p_q_const__void_size_t__ssize_t", "ssize_t (**)(void *,void const *,size_t)|GpgmeDataWriteCb *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_f_p_void_p_void_size_t__ssize_t = {"_p_p_f_p_void_p_void_size_t__ssize_t", "ssize_t (**)(void *,void *,size_t)|GpgmeDataReadCb *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_gpgme_conf_arg = {"_p_p_gpgme_conf_arg", "gpgme_conf_arg_t *|struct gpgme_conf_arg **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_gpgme_conf_comp = {"_p_p_gpgme_conf_comp", "struct gpgme_conf_comp **|gpgme_conf_comp_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_gpgme_conf_opt = {"_p_p_gpgme_conf_opt", "struct gpgme_conf_opt **|gpgme_conf_opt_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_gpgme_context = {"_p_p_gpgme_context", "gpgme_ctx_t *|struct gpgme_context **|GpgmeCtx *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_gpgme_data = {"_p_p_gpgme_data", "gpgme_data_t *|GpgmeData *|struct gpgme_data **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_void = {"_p_p_void", "void **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_size_t = {"_p_size_t", "size_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_ssize_t = {"_p_ssize_t", "ssize_t *|gpgme_ssize_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_time_t = {"_p_time_t", "time_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_unsigned_int = {"_p_unsigned_int", "unsigned int *|gpgme_sig_notation_flags_t *|gpgme_keylist_mode_t *|gpgme_export_mode_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_void = {"_p_void", "void *", 0, 0, (void*)0, 0};

static swig_type_info *swig_type_initial[] = {
  &_swigt__p_FILE,
  &_swigt__p__gpgme_attr_t,
  &_swigt__p__gpgme_engine_info,
  &_swigt__p__gpgme_import_status,
  &_swigt__p__gpgme_invalid_key,
  &_swigt__p__gpgme_key,
  &_swigt__p__gpgme_key_sig,
  &_swigt__p__gpgme_new_signature,
  &_swigt__p__gpgme_op_assuan_result,
  &_swigt__p__gpgme_op_decrypt_result,
  &_swigt__p__gpgme_op_encrypt_result,
  &_swigt__p__gpgme_op_genkey_result,
  &_swigt__p__gpgme_op_import_result,
  &_swigt__p__gpgme_op_keylist_result,
  &_swigt__p__gpgme_op_query_swdb_result,
  &_swigt__p__gpgme_op_sign_result,
  &_swigt__p__gpgme_op_verify_result,
  &_swigt__p__gpgme_op_vfs_mount_result,
  &_swigt__p__gpgme_recipient,
  &_swigt__p__gpgme_sig_notation,
  &_swigt__p__gpgme_sig_stat_t,
  &_swigt__p__gpgme_signature,
  &_swigt__p__gpgme_subkey,
  &_swigt__p__gpgme_tofu_info,
  &_swigt__p__gpgme_trust_item,
  &_swigt__p__gpgme_user_id,
  &_swigt__p_a___p__gpgme_key,
  &_swigt__p_char,
  &_swigt__p_f_p_void__void,
  &_swigt__p_f_p_void_enum_gpgme_event_io_t_p_void__void,
  &_swigt__p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t,
  &_swigt__p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t,
  &_swigt__p_f_p_void_off_t_int__off_t,
  &_swigt__p_f_p_void_p_char_size_t_p_size_t__int,
  &_swigt__p_f_p_void_p_q_const__char_int_int_int__void,
  &_swigt__p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t,
  &_swigt__p_f_p_void_p_q_const__char_p_q_const__char_int__gpg_error_t,
  &_swigt__p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t,
  &_swigt__p_f_p_void_p_q_const__char_p_q_const__char_p_p_struct_gpgme_data__gpg_error_t,
  &_swigt__p_f_p_void_p_q_const__void_size_t__gpg_error_t,
  &_swigt__p_f_p_void_p_q_const__void_size_t__ssize_t,
  &_swigt__p_f_p_void_p_void_size_t__ssize_t,
  &_swigt__p_gpg_err_code_t,
  &_swigt__p_gpg_err_source_t,
  &_swigt__p_gpg_error_t,
  &_swigt__p_gpgme_conf_arg,
  &_swigt__p_gpgme_conf_arg_value,
  &_swigt__p_gpgme_conf_comp,
  &_swigt__p_gpgme_conf_level_t,
  &_swigt__p_gpgme_conf_opt,
  &_swigt__p_gpgme_conf_type_t,
  &_swigt__p_gpgme_context,
  &_swigt__p_gpgme_data,
  &_swigt__p_gpgme_data_cbs,
  &_swigt__p_gpgme_data_encoding_t,
  &_swigt__p_gpgme_data_type_t,
  &_swigt__p_gpgme_decrypt_flags_t,
  &_swigt__p_gpgme_encrypt_flags_t,
  &_swigt__p_gpgme_event_io_t,
  &_swigt__p_gpgme_hash_algo_t,
  &_swigt__p_gpgme_io_cbs,
  &_swigt__p_gpgme_io_event_done_data,
  &_swigt__p_gpgme_keyorg_t,
  &_swigt__p_gpgme_pinentry_mode_t,
  &_swigt__p_gpgme_protocol_t,
  &_swigt__p_gpgme_pubkey_algo_t,
  &_swigt__p_gpgme_sig_mode_t,
  &_swigt__p_gpgme_sigsum_t,
  &_swigt__p_gpgme_status_code_t,
  &_swigt__p_gpgme_tofu_policy_t,
  &_swigt__p_gpgme_validity_t,
  &_swigt__p_gpgrt_stream_t,
  &_swigt__p_int,
  &_swigt__p_off_t,
  &_swigt__p_p__gpgme_engine_info,
  &_swigt__p_p__gpgme_import_status,
  &_swigt__p_p__gpgme_key,
  &_swigt__p_p__gpgme_key_sig,
  &_swigt__p_p__gpgme_op_encrypt_result,
  &_swigt__p_p__gpgme_op_genkey_result,
  &_swigt__p_p__gpgme_op_import_result,
  &_swigt__p_p__gpgme_op_verify_result,
  &_swigt__p_p__gpgme_sig_notation,
  &_swigt__p_p__gpgme_signature,
  &_swigt__p_p__gpgme_subkey,
  &_swigt__p_p__gpgme_trust_item,
  &_swigt__p_p__gpgme_user_id,
  &_swigt__p_p_char,
  &_swigt__p_p_f_p_void__void,
  &_swigt__p_p_f_p_void_enum_gpgme_event_io_t_p_void__void,
  &_swigt__p_p_f_p_void_int__gpg_error_t,
  &_swigt__p_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t,
  &_swigt__p_p_f_p_void_off_t_int__off_t,
  &_swigt__p_p_f_p_void_p_q_const__char_int_int_int__void,
  &_swigt__p_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t,
  &_swigt__p_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t,
  &_swigt__p_p_f_p_void_p_q_const__void_size_t__ssize_t,
  &_swigt__p_p_f_p_void_p_void_size_t__ssize_t,
  &_swigt__p_p_gpgme_conf_arg,
  &_swigt__p_p_gpgme_conf_comp,
  &_swigt__p_p_gpgme_conf_opt,
  &_swigt__p_p_gpgme_context,
  &_swigt__p_p_gpgme_data,
  &_swigt__p_p_void,
  &_swigt__p_size_t,
  &_swigt__p_ssize_t,
  &_swigt__p_time_t,
  &_swigt__p_unsigned_int,
  &_swigt__p_void,
};

static swig_cast_info _swigc__p_FILE[] = {  {&_swigt__p_FILE, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_attr_t[] = {  {&_swigt__p__gpgme_attr_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_engine_info[] = {  {&_swigt__p__gpgme_engine_info, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_import_status[] = {  {&_swigt__p__gpgme_import_status, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_invalid_key[] = {  {&_swigt__p__gpgme_invalid_key, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_key[] = {  {&_swigt__p__gpgme_key, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_key_sig[] = {  {&_swigt__p__gpgme_key_sig, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_new_signature[] = {  {&_swigt__p__gpgme_new_signature, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_assuan_result[] = {  {&_swigt__p__gpgme_op_assuan_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_decrypt_result[] = {  {&_swigt__p__gpgme_op_decrypt_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_encrypt_result[] = {  {&_swigt__p__gpgme_op_encrypt_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_genkey_result[] = {  {&_swigt__p__gpgme_op_genkey_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_import_result[] = {  {&_swigt__p__gpgme_op_import_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_keylist_result[] = {  {&_swigt__p__gpgme_op_keylist_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_query_swdb_result[] = {  {&_swigt__p__gpgme_op_query_swdb_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_sign_result[] = {  {&_swigt__p__gpgme_op_sign_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_verify_result[] = {  {&_swigt__p__gpgme_op_verify_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_op_vfs_mount_result[] = {  {&_swigt__p__gpgme_op_vfs_mount_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_recipient[] = {  {&_swigt__p__gpgme_recipient, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_sig_notation[] = {  {&_swigt__p__gpgme_sig_notation, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_sig_stat_t[] = {  {&_swigt__p__gpgme_sig_stat_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_signature[] = {  {&_swigt__p__gpgme_signature, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_subkey[] = {  {&_swigt__p__gpgme_subkey, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_tofu_info[] = {  {&_swigt__p__gpgme_tofu_info, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_trust_item[] = {  {&_swigt__p__gpgme_trust_item, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gpgme_user_id[] = {  {&_swigt__p__gpgme_user_id, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_a___p__gpgme_key[] = {  {&_swigt__p_a___p__gpgme_key, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_char[] = {  {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void__void[] = {  {&_swigt__p_f_p_void__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_enum_gpgme_event_io_t_p_void__void[] = {  {&_swigt__p_f_p_void_enum_gpgme_event_io_t_p_void__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t[] = {  {&_swigt__p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t[] = {  {&_swigt__p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_off_t_int__off_t[] = {  {&_swigt__p_f_p_void_off_t_int__off_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_char_size_t_p_size_t__int[] = {  {&_swigt__p_f_p_void_p_char_size_t_p_size_t__int, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_q_const__char_int_int_int__void[] = {  {&_swigt__p_f_p_void_p_q_const__char_int_int_int__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t[] = {  {&_swigt__p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_q_const__char_p_q_const__char_int__gpg_error_t[] = {  {&_swigt__p_f_p_void_p_q_const__char_p_q_const__char_int__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t[] = {  {&_swigt__p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_q_const__char_p_q_const__char_p_p_struct_gpgme_data__gpg_error_t[] = {  {&_swigt__p_f_p_void_p_q_const__char_p_q_const__char_p_p_struct_gpgme_data__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_q_const__void_size_t__gpg_error_t[] = {  {&_swigt__p_f_p_void_p_q_const__void_size_t__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_q_const__void_size_t__ssize_t[] = {  {&_swigt__p_f_p_void_p_q_const__void_size_t__ssize_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_void_p_void_size_t__ssize_t[] = {  {&_swigt__p_f_p_void_p_void_size_t__ssize_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpg_err_code_t[] = {  {&_swigt__p_gpg_err_code_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpg_err_source_t[] = {  {&_swigt__p_gpg_err_source_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpg_error_t[] = {  {&_swigt__p_gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_conf_arg[] = {  {&_swigt__p_gpgme_conf_arg, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_conf_arg_value[] = {  {&_swigt__p_gpgme_conf_arg_value, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_conf_comp[] = {  {&_swigt__p_gpgme_conf_comp, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_conf_level_t[] = {  {&_swigt__p_gpgme_conf_level_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_conf_opt[] = {  {&_swigt__p_gpgme_conf_opt, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_conf_type_t[] = {  {&_swigt__p_gpgme_conf_type_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_context[] = {  {&_swigt__p_gpgme_context, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_data[] = {  {&_swigt__p_gpgme_data, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_data_cbs[] = {  {&_swigt__p_gpgme_data_cbs, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_data_encoding_t[] = {  {&_swigt__p_gpgme_data_encoding_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_data_type_t[] = {  {&_swigt__p_gpgme_data_type_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_decrypt_flags_t[] = {  {&_swigt__p_gpgme_decrypt_flags_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_encrypt_flags_t[] = {  {&_swigt__p_gpgme_encrypt_flags_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_event_io_t[] = {  {&_swigt__p_gpgme_event_io_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_hash_algo_t[] = {  {&_swigt__p_gpgme_hash_algo_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_io_cbs[] = {  {&_swigt__p_gpgme_io_cbs, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_io_event_done_data[] = {  {&_swigt__p_gpgme_io_event_done_data, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_keyorg_t[] = {  {&_swigt__p_gpgme_keyorg_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_pinentry_mode_t[] = {  {&_swigt__p_gpgme_pinentry_mode_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_protocol_t[] = {  {&_swigt__p_gpgme_protocol_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_pubkey_algo_t[] = {  {&_swigt__p_gpgme_pubkey_algo_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_sig_mode_t[] = {  {&_swigt__p_gpgme_sig_mode_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_sigsum_t[] = {  {&_swigt__p_gpgme_sigsum_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_status_code_t[] = {  {&_swigt__p_gpgme_status_code_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_tofu_policy_t[] = {  {&_swigt__p_gpgme_tofu_policy_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgme_validity_t[] = {  {&_swigt__p_gpgme_validity_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gpgrt_stream_t[] = {  {&_swigt__p_gpgrt_stream_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_int[] = {  {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_off_t[] = {  {&_swigt__p_off_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_engine_info[] = {  {&_swigt__p_p__gpgme_engine_info, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_import_status[] = {  {&_swigt__p_p__gpgme_import_status, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_key[] = {  {&_swigt__p_p__gpgme_key, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_key_sig[] = {  {&_swigt__p_p__gpgme_key_sig, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_op_encrypt_result[] = {  {&_swigt__p_p__gpgme_op_encrypt_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_op_genkey_result[] = {  {&_swigt__p_p__gpgme_op_genkey_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_op_import_result[] = {  {&_swigt__p_p__gpgme_op_import_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_op_verify_result[] = {  {&_swigt__p_p__gpgme_op_verify_result, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_sig_notation[] = {  {&_swigt__p_p__gpgme_sig_notation, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_signature[] = {  {&_swigt__p_p__gpgme_signature, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_subkey[] = {  {&_swigt__p_p__gpgme_subkey, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_trust_item[] = {  {&_swigt__p_p__gpgme_trust_item, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p__gpgme_user_id[] = {  {&_swigt__p_p__gpgme_user_id, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_char[] = {  {&_swigt__p_p_char, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void__void[] = {  {&_swigt__p_p_f_p_void__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_enum_gpgme_event_io_t_p_void__void[] = {  {&_swigt__p_p_f_p_void_enum_gpgme_event_io_t_p_void__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_int__gpg_error_t[] = {  {&_swigt__p_p_f_p_void_int__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t[] = {  {&_swigt__p_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_off_t_int__off_t[] = {  {&_swigt__p_p_f_p_void_off_t_int__off_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_p_q_const__char_int_int_int__void[] = {  {&_swigt__p_p_f_p_void_p_q_const__char_int_int_int__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t[] = {  {&_swigt__p_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t[] = {  {&_swigt__p_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_p_q_const__void_size_t__ssize_t[] = {  {&_swigt__p_p_f_p_void_p_q_const__void_size_t__ssize_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_f_p_void_p_void_size_t__ssize_t[] = {  {&_swigt__p_p_f_p_void_p_void_size_t__ssize_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_gpgme_conf_arg[] = {  {&_swigt__p_p_gpgme_conf_arg, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_gpgme_conf_comp[] = {  {&_swigt__p_p_gpgme_conf_comp, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_gpgme_conf_opt[] = {  {&_swigt__p_p_gpgme_conf_opt, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_gpgme_context[] = {  {&_swigt__p_p_gpgme_context, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_gpgme_data[] = {  {&_swigt__p_p_gpgme_data, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_void[] = {  {&_swigt__p_p_void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_size_t[] = {  {&_swigt__p_size_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ssize_t[] = {  {&_swigt__p_ssize_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_time_t[] = {  {&_swigt__p_time_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_unsigned_int[] = {  {&_swigt__p_unsigned_int, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_void[] = {  {&_swigt__p_void, 0, 0, 0},{0, 0, 0, 0}};

static swig_cast_info *swig_cast_initial[] = {
  _swigc__p_FILE,
  _swigc__p__gpgme_attr_t,
  _swigc__p__gpgme_engine_info,
  _swigc__p__gpgme_import_status,
  _swigc__p__gpgme_invalid_key,
  _swigc__p__gpgme_key,
  _swigc__p__gpgme_key_sig,
  _swigc__p__gpgme_new_signature,
  _swigc__p__gpgme_op_assuan_result,
  _swigc__p__gpgme_op_decrypt_result,
  _swigc__p__gpgme_op_encrypt_result,
  _swigc__p__gpgme_op_genkey_result,
  _swigc__p__gpgme_op_import_result,
  _swigc__p__gpgme_op_keylist_result,
  _swigc__p__gpgme_op_query_swdb_result,
  _swigc__p__gpgme_op_sign_result,
  _swigc__p__gpgme_op_verify_result,
  _swigc__p__gpgme_op_vfs_mount_result,
  _swigc__p__gpgme_recipient,
  _swigc__p__gpgme_sig_notation,
  _swigc__p__gpgme_sig_stat_t,
  _swigc__p__gpgme_signature,
  _swigc__p__gpgme_subkey,
  _swigc__p__gpgme_tofu_info,
  _swigc__p__gpgme_trust_item,
  _swigc__p__gpgme_user_id,
  _swigc__p_a___p__gpgme_key,
  _swigc__p_char,
  _swigc__p_f_p_void__void,
  _swigc__p_f_p_void_enum_gpgme_event_io_t_p_void__void,
  _swigc__p_f_p_void_enum_gpgme_status_code_t_p_q_const__char_int__gpg_error_t,
  _swigc__p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t,
  _swigc__p_f_p_void_off_t_int__off_t,
  _swigc__p_f_p_void_p_char_size_t_p_size_t__int,
  _swigc__p_f_p_void_p_q_const__char_int_int_int__void,
  _swigc__p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t,
  _swigc__p_f_p_void_p_q_const__char_p_q_const__char_int__gpg_error_t,
  _swigc__p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t,
  _swigc__p_f_p_void_p_q_const__char_p_q_const__char_p_p_struct_gpgme_data__gpg_error_t,
  _swigc__p_f_p_void_p_q_const__void_size_t__gpg_error_t,
  _swigc__p_f_p_void_p_q_const__void_size_t__ssize_t,
  _swigc__p_f_p_void_p_void_size_t__ssize_t,
  _swigc__p_gpg_err_code_t,
  _swigc__p_gpg_err_source_t,
  _swigc__p_gpg_error_t,
  _swigc__p_gpgme_conf_arg,
  _swigc__p_gpgme_conf_arg_value,
  _swigc__p_gpgme_conf_comp,
  _swigc__p_gpgme_conf_level_t,
  _swigc__p_gpgme_conf_opt,
  _swigc__p_gpgme_conf_type_t,
  _swigc__p_gpgme_context,
  _swigc__p_gpgme_data,
  _swigc__p_gpgme_data_cbs,
  _swigc__p_gpgme_data_encoding_t,
  _swigc__p_gpgme_data_type_t,
  _swigc__p_gpgme_decrypt_flags_t,
  _swigc__p_gpgme_encrypt_flags_t,
  _swigc__p_gpgme_event_io_t,
  _swigc__p_gpgme_hash_algo_t,
  _swigc__p_gpgme_io_cbs,
  _swigc__p_gpgme_io_event_done_data,
  _swigc__p_gpgme_keyorg_t,
  _swigc__p_gpgme_pinentry_mode_t,
  _swigc__p_gpgme_protocol_t,
  _swigc__p_gpgme_pubkey_algo_t,
  _swigc__p_gpgme_sig_mode_t,
  _swigc__p_gpgme_sigsum_t,
  _swigc__p_gpgme_status_code_t,
  _swigc__p_gpgme_tofu_policy_t,
  _swigc__p_gpgme_validity_t,
  _swigc__p_gpgrt_stream_t,
  _swigc__p_int,
  _swigc__p_off_t,
  _swigc__p_p__gpgme_engine_info,
  _swigc__p_p__gpgme_import_status,
  _swigc__p_p__gpgme_key,
  _swigc__p_p__gpgme_key_sig,
  _swigc__p_p__gpgme_op_encrypt_result,
  _swigc__p_p__gpgme_op_genkey_result,
  _swigc__p_p__gpgme_op_import_result,
  _swigc__p_p__gpgme_op_verify_result,
  _swigc__p_p__gpgme_sig_notation,
  _swigc__p_p__gpgme_signature,
  _swigc__p_p__gpgme_subkey,
  _swigc__p_p__gpgme_trust_item,
  _swigc__p_p__gpgme_user_id,
  _swigc__p_p_char,
  _swigc__p_p_f_p_void__void,
  _swigc__p_p_f_p_void_enum_gpgme_event_io_t_p_void__void,
  _swigc__p_p_f_p_void_int__gpg_error_t,
  _swigc__p_p_f_p_void_int_int_p_f_p_void_int__gpg_error_t_p_void_p_p_void__gpg_error_t,
  _swigc__p_p_f_p_void_off_t_int__off_t,
  _swigc__p_p_f_p_void_p_q_const__char_int_int_int__void,
  _swigc__p_p_f_p_void_p_q_const__char_p_q_const__char__gpg_error_t,
  _swigc__p_p_f_p_void_p_q_const__char_p_q_const__char_int_int__gpg_error_t,
  _swigc__p_p_f_p_void_p_q_const__void_size_t__ssize_t,
  _swigc__p_p_f_p_void_p_void_size_t__ssize_t,
  _swigc__p_p_gpgme_conf_arg,
  _swigc__p_p_gpgme_conf_comp,
  _swigc__p_p_gpgme_conf_opt,
  _swigc__p_p_gpgme_context,
  _swigc__p_p_gpgme_data,
  _swigc__p_p_void,
  _swigc__p_size_t,
  _swigc__p_ssize_t,
  _swigc__p_time_t,
  _swigc__p_unsigned_int,
  _swigc__p_void,
};


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

static swig_const_info swig_const_table[] = {
{0, 0, 0, 0.0, 0, 0}};

#ifdef __cplusplus
}
#endif
/* -----------------------------------------------------------------------------
 * Type initialization:
 * This problem is tough by the requirement that no dynamic
 * memory is used. Also, since swig_type_info structures store pointers to
 * swig_cast_info structures and swig_cast_info structures store pointers back
 * to swig_type_info structures, we need some lookup code at initialization.
 * The idea is that swig generates all the structures that are needed.
 * The runtime then collects these partially filled structures.
 * The SWIG_InitializeModule function takes these initial arrays out of
 * swig_module, and does all the lookup, filling in the swig_module.types
 * array with the correct data and linking the correct swig_cast_info
 * structures together.
 *
 * The generated swig_type_info structures are assigned statically to an initial
 * array. We just loop through that array, and handle each type individually.
 * First we lookup if this type has been already loaded, and if so, use the
 * loaded structure instead of the generated one. Then we have to fill in the
 * cast linked list. The cast data is initially stored in something like a
 * two-dimensional array. Each row corresponds to a type (there are the same
 * number of rows as there are in the swig_type_initial array). Each entry in
 * a column is one of the swig_cast_info structures for that type.
 * The cast_initial array is actually an array of arrays, because each row has
 * a variable number of columns. So to actually build the cast linked list,
 * we find the array of casts associated with the type, and loop through it
 * adding the casts to the list. The one last trick we need to do is making
 * sure the type pointer in the swig_cast_info struct is correct.
 *
 * First off, we lookup the cast->type name to see if it is already loaded.
 * There are three cases to handle:
 *  1) If the cast->type has already been loaded AND the type we are adding
 *     casting info to has not been loaded (it is in this module), THEN we
 *     replace the cast->type pointer with the type pointer that has already
 *     been loaded.
 *  2) If BOTH types (the one we are adding casting info to, and the
 *     cast->type) are loaded, THEN the cast info has already been loaded by
 *     the previous module so we just ignore it.
 *  3) Finally, if cast->type has not already been loaded, then we add that
 *     swig_cast_info to the linked list (because the cast->type) pointer will
 *     be correct.
 * ----------------------------------------------------------------------------- */

#ifdef __cplusplus
extern "C" {
#if 0
} /* c-mode */
#endif
#endif

#if 0
#define SWIGRUNTIME_DEBUG
#endif


SWIGRUNTIME void
SWIG_InitializeModule(void *clientdata) {
  size_t i;
  swig_module_info *module_head, *iter;
  int init;
  
  /* check to see if the circular list has been setup, if not, set it up */
  if (swig_module.next==0) {
    /* Initialize the swig_module */
    swig_module.type_initial = swig_type_initial;
    swig_module.cast_initial = swig_cast_initial;
    swig_module.next = &swig_module;
    init = 1;
  } else {
    init = 0;
  }
  
  /* Try and load any already created modules */
  module_head = SWIG_GetModule(clientdata);
  if (!module_head) {
    /* This is the first module loaded for this interpreter */
    /* so set the swig module into the interpreter */
    SWIG_SetModule(clientdata, &swig_module);
  } else {
    /* the interpreter has loaded a SWIG module, but has it loaded this one? */
    iter=module_head;
    do {
      if (iter==&swig_module) {
        /* Our module is already in the list, so there's nothing more to do. */
        return;
      }
      iter=iter->next;
    } while (iter!= module_head);
    
    /* otherwise we must add our module into the list */
    swig_module.next = module_head->next;
    module_head->next = &swig_module;
  }
  
  /* When multiple interpreters are used, a module could have already been initialized in
       a different interpreter, but not yet have a pointer in this interpreter.
       In this case, we do not want to continue adding types... everything should be
       set up already */
  if (init == 0) return;
  
  /* Now work on filling in swig_module.types */
#ifdef SWIGRUNTIME_DEBUG
  printf("SWIG_InitializeModule: size %d\n", swig_module.size);
#endif
  for (i = 0; i < swig_module.size; ++i) {
    swig_type_info *type = 0;
    swig_type_info *ret;
    swig_cast_info *cast;
    
#ifdef SWIGRUNTIME_DEBUG
    printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
#endif
    
    /* if there is another module already loaded */
    if (swig_module.next != &swig_module) {
      type = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, swig_module.type_initial[i]->name);
    }
    if (type) {
      /* Overwrite clientdata field */
#ifdef SWIGRUNTIME_DEBUG
      printf("SWIG_InitializeModule: found type %s\n", type->name);
#endif
      if (swig_module.type_initial[i]->clientdata) {
        type->clientdata = swig_module.type_initial[i]->clientdata;
#ifdef SWIGRUNTIME_DEBUG
        printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name);
#endif
      }
    } else {
      type = swig_module.type_initial[i];
    }
    
    /* Insert casting types */
    cast = swig_module.cast_initial[i];
    while (cast->type) {
      /* Don't need to add information already in the list */
      ret = 0;
#ifdef SWIGRUNTIME_DEBUG
      printf("SWIG_InitializeModule: look cast %s\n", cast->type->name);
#endif
      if (swig_module.next != &swig_module) {
        ret = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, cast->type->name);
#ifdef SWIGRUNTIME_DEBUG
        if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name);
#endif
      }
      if (ret) {
        if (type == swig_module.type_initial[i]) {
#ifdef SWIGRUNTIME_DEBUG
          printf("SWIG_InitializeModule: skip old type %s\n", ret->name);
#endif
          cast->type = ret;
          ret = 0;
        } else {
          /* Check for casting already in the list */
          swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type);
#ifdef SWIGRUNTIME_DEBUG
          if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name);
#endif
          if (!ocast) ret = 0;
        }
      }
      
      if (!ret) {
#ifdef SWIGRUNTIME_DEBUG
        printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name);
#endif
        if (type->cast) {
          type->cast->prev = cast;
          cast->next = type->cast;
        }
        type->cast = cast;
      }
      cast++;
    }
    /* Set entry in modules->types array equal to the type */
    swig_module.types[i] = type;
  }
  swig_module.types[i] = 0;
  
#ifdef SWIGRUNTIME_DEBUG
  printf("**** SWIG_InitializeModule: Cast List ******\n");
  for (i = 0; i < swig_module.size; ++i) {
    int j = 0;
    swig_cast_info *cast = swig_module.cast_initial[i];
    printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
    while (cast->type) {
      printf("SWIG_InitializeModule: cast type %s\n", cast->type->name);
      cast++;
      ++j;
    }
    printf("---- Total casts: %d\n",j);
  }
  printf("**** SWIG_InitializeModule: Cast List ******\n");
#endif
}

/* This function will propagate the clientdata field of type to
* any new swig_type_info structures that have been added into the list
* of equivalent types.  It is like calling
* SWIG_TypeClientData(type, clientdata) a second time.
*/
SWIGRUNTIME void
SWIG_PropagateClientData(void) {
  size_t i;
  swig_cast_info *equiv;
  static int init_run = 0;
  
  if (init_run) return;
  init_run = 1;
  
  for (i = 0; i < swig_module.size; i++) {
    if (swig_module.types[i]->clientdata) {
      equiv = swig_module.types[i]->cast;
      while (equiv) {
        if (!equiv->converter) {
          if (equiv->type && !equiv->type->clientdata)
          SWIG_TypeClientData(equiv->type, swig_module.types[i]->clientdata);
        }
        equiv = equiv->next;
      }
    }
  }
}

#ifdef __cplusplus
#if 0
{
  /* c-mode */
#endif
}
#endif



#ifdef __cplusplus
extern "C" {
#endif
  
  /* Python-specific SWIG API */
#define SWIG_newvarlink()                             SWIG_Python_newvarlink()
#define SWIG_addvarlink(p, name, get_attr, set_attr)  SWIG_Python_addvarlink(p, name, get_attr, set_attr)
#define SWIG_InstallConstants(d, constants)           SWIG_Python_InstallConstants(d, constants)
  
  /* -----------------------------------------------------------------------------
   * global variable support code.
   * ----------------------------------------------------------------------------- */
  
  typedef struct swig_globalvar {
    char       *name;                  /* Name of global variable */
    PyObject *(*get_attr)(void);       /* Return the current value */
    int       (*set_attr)(PyObject *); /* Set the value */
    struct swig_globalvar *next;
  } swig_globalvar;
  
  typedef struct swig_varlinkobject {
    PyObject_HEAD
    swig_globalvar *vars;
  } swig_varlinkobject;
  
  SWIGINTERN PyObject *
  swig_varlink_repr(swig_varlinkobject *SWIGUNUSEDPARM(v)) {
#if PY_VERSION_HEX >= 0x03000000
    return PyUnicode_InternFromString("<Swig global variables>");
#else
    return PyString_FromString("<Swig global variables>");
#endif
  }
  
  SWIGINTERN PyObject *
  swig_varlink_str(swig_varlinkobject *v) {
#if PY_VERSION_HEX >= 0x03000000
    PyObject *str = PyUnicode_InternFromString("(");
    PyObject *tail;
    PyObject *joined;
    swig_globalvar *var;
    for (var = v->vars; var; var=var->next) {
      tail = PyUnicode_FromString(var->name);
      joined = PyUnicode_Concat(str, tail);
      Py_DecRef(str);
      Py_DecRef(tail);
      str = joined;
      if (var->next) {
        tail = PyUnicode_InternFromString(", ");
        joined = PyUnicode_Concat(str, tail);
        Py_DecRef(str);
        Py_DecRef(tail);
        str = joined;
      }
    }
    tail = PyUnicode_InternFromString(")");
    joined = PyUnicode_Concat(str, tail);
    Py_DecRef(str);
    Py_DecRef(tail);
    str = joined;
#else
    PyObject *str = PyString_FromString("(");
    swig_globalvar *var;
    for (var = v->vars; var; var=var->next) {
      PyString_ConcatAndDel(&str,PyString_FromString(var->name));
      if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", "));
    }
    PyString_ConcatAndDel(&str,PyString_FromString(")"));
#endif
    return str;
  }
  
  SWIGINTERN int
  swig_varlink_print(swig_varlinkobject *v, FILE *fp, int SWIGUNUSEDPARM(flags)) {
    char *tmp;
    PyObject *str = swig_varlink_str(v);
    fprintf(fp,"Swig global variables ");
    fprintf(fp,"%s\n", tmp = SWIG_Python_str_AsChar(str));
    SWIG_Python_str_DelForPy3(tmp);
    Py_DECREF(str);
    return 0;
  }
  
  SWIGINTERN void
  swig_varlink_dealloc(swig_varlinkobject *v) {
    swig_globalvar *var = v->vars;
    while (var) {
      swig_globalvar *n = var->next;
      free(var->name);
      free(var);
      var = n;
    }
  }
  
  SWIGINTERN PyObject *
  swig_varlink_getattr(swig_varlinkobject *v, char *n) {
    PyObject *res = NULL;
    swig_globalvar *var = v->vars;
    while (var) {
      if (strcmp(var->name,n) == 0) {
        res = (*var->get_attr)();
        break;
      }
      var = var->next;
    }
    if (res == NULL && !PyErr_Occurred()) {
      PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
    }
    return res;
  }
  
  SWIGINTERN int
  swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) {
    int res = 1;
    swig_globalvar *var = v->vars;
    while (var) {
      if (strcmp(var->name,n) == 0) {
        res = (*var->set_attr)(p);
        break;
      }
      var = var->next;
    }
    if (res == 1 && !PyErr_Occurred()) {
      PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
    }
    return res;
  }
  
  SWIGINTERN PyTypeObject*
  swig_varlink_type(void) {
    static char varlink__doc__[] = "Swig var link object";
    static PyTypeObject varlink_type;
    static int type_init = 0;
    if (!type_init) {
      const PyTypeObject tmp = {
#if PY_VERSION_HEX >= 0x03000000
        PyVarObject_HEAD_INIT(NULL, 0)
#else
        PyObject_HEAD_INIT(NULL)
        0,                                  /* ob_size */
#endif
        (char *)"swigvarlink",              /* tp_name */
        sizeof(swig_varlinkobject),         /* tp_basicsize */
        0,                                  /* tp_itemsize */
        (destructor) swig_varlink_dealloc,  /* tp_dealloc */
        (printfunc) swig_varlink_print,     /* tp_print */
        (getattrfunc) swig_varlink_getattr, /* tp_getattr */
        (setattrfunc) swig_varlink_setattr, /* tp_setattr */
        0,                                  /* tp_compare */
        (reprfunc) swig_varlink_repr,       /* tp_repr */
        0,                                  /* tp_as_number */
        0,                                  /* tp_as_sequence */
        0,                                  /* tp_as_mapping */
        0,                                  /* tp_hash */
        0,                                  /* tp_call */
        (reprfunc) swig_varlink_str,        /* tp_str */
        0,                                  /* tp_getattro */
        0,                                  /* tp_setattro */
        0,                                  /* tp_as_buffer */
        0,                                  /* tp_flags */
        varlink__doc__,                     /* tp_doc */
        0,                                  /* tp_traverse */
        0,                                  /* tp_clear */
        0,                                  /* tp_richcompare */
        0,                                  /* tp_weaklistoffset */
#if PY_VERSION_HEX >= 0x02020000
        0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
#endif
#if PY_VERSION_HEX >= 0x02030000
        0,                                  /* tp_del */
#endif
#if PY_VERSION_HEX >= 0x02060000
        0,                                  /* tp_version_tag */
#endif
#if PY_VERSION_HEX >= 0x03040000
        0,                                  /* tp_finalize */
#endif
#ifdef COUNT_ALLOCS
        0,                                  /* tp_allocs */
        0,                                  /* tp_frees */
        0,                                  /* tp_maxalloc */
#if PY_VERSION_HEX >= 0x02050000
        0,                                  /* tp_prev */
#endif
        0                                   /* tp_next */
#endif
      };
      varlink_type = tmp;
      type_init = 1;
#if PY_VERSION_HEX < 0x02020000
      varlink_type.ob_type = &PyType_Type;
#else
      if (PyType_Ready(&varlink_type) < 0)
      return NULL;
#endif
    }
    return &varlink_type;
  }
  
  /* Create a variable linking object for use later */
  SWIGINTERN PyObject *
  SWIG_Python_newvarlink(void) {
    swig_varlinkobject *result = PyObject_NEW(swig_varlinkobject, swig_varlink_type());
    if (result) {
      result->vars = 0;
    }
    return ((PyObject*) result);
  }
  
  SWIGINTERN void 
  SWIG_Python_addvarlink(PyObject *p, char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) {
    swig_varlinkobject *v = (swig_varlinkobject *) p;
    swig_globalvar *gv = (swig_globalvar *) malloc(sizeof(swig_globalvar));
    if (gv) {
      size_t size = strlen(name)+1;
      gv->name = (char *)malloc(size);
      if (gv->name) {
        strncpy(gv->name,name,size);
        gv->get_attr = get_attr;
        gv->set_attr = set_attr;
        gv->next = v->vars;
      }
    }
    v->vars = gv;
  }
  
  SWIGINTERN PyObject *
  SWIG_globals(void) {
    static PyObject *_SWIG_globals = 0; 
    if (!_SWIG_globals) _SWIG_globals = SWIG_newvarlink();  
    return _SWIG_globals;
  }
  
  /* -----------------------------------------------------------------------------
   * constants/methods manipulation
   * ----------------------------------------------------------------------------- */
  
  /* Install Constants */
  SWIGINTERN void
  SWIG_Python_InstallConstants(PyObject *d, swig_const_info constants[]) {
    PyObject *obj = 0;
    size_t i;
    for (i = 0; constants[i].type; ++i) {
      switch(constants[i].type) {
      case SWIG_PY_POINTER:
        obj = SWIG_InternalNewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
        break;
      case SWIG_PY_BINARY:
        obj = SWIG_NewPackedObj(constants[i].pvalue, constants[i].lvalue, *(constants[i].ptype));
        break;
      default:
        obj = 0;
        break;
      }
      if (obj) {
        PyDict_SetItemString(d, constants[i].name, obj);
        Py_DECREF(obj);
      }
    }
  }
  
  /* -----------------------------------------------------------------------------*/
  /* Fix SwigMethods to carry the callback ptrs when needed */
  /* -----------------------------------------------------------------------------*/
  
  SWIGINTERN void
  SWIG_Python_FixMethods(PyMethodDef *methods,
    swig_const_info *const_table,
    swig_type_info **types,
    swig_type_info **types_initial) {
    size_t i;
    for (i = 0; methods[i].ml_name; ++i) {
      const char *c = methods[i].ml_doc;
      if (!c) continue;
      c = strstr(c, "swig_ptr: ");
      if (c) {
        int j;
        swig_const_info *ci = 0;
        const char *name = c + 10;
        for (j = 0; const_table[j].type; ++j) {
          if (strncmp(const_table[j].name, name, 
              strlen(const_table[j].name)) == 0) {
            ci = &(const_table[j]);
            break;
          }
        }
        if (ci) {
          void *ptr = (ci->type == SWIG_PY_POINTER) ? ci->pvalue : 0;
          if (ptr) {
            size_t shift = (ci->ptype) - types;
            swig_type_info *ty = types_initial[shift];
            size_t ldoc = (c - methods[i].ml_doc);
            size_t lptr = strlen(ty->name)+2*sizeof(void*)+2;
            char *ndoc = (char*)malloc(ldoc + lptr + 10);
            if (ndoc) {
              char *buff = ndoc;
              memcpy(buff, methods[i].ml_doc, ldoc);
              buff += ldoc;
              memcpy(buff, "swig_ptr: ", 10);
              buff += 10;
              SWIG_PackVoidPtr(buff, ptr, ty->name, lptr);
              methods[i].ml_doc = ndoc;
            }
          }
        }
      }
    }
  } 
  
#ifdef __cplusplus
}
#endif

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

#ifdef __cplusplus
extern "C"
#endif

SWIGEXPORT 
#if PY_VERSION_HEX >= 0x03000000
PyObject*
#else
void
#endif
SWIG_init(void) {
  PyObject *m, *d, *md;
#if PY_VERSION_HEX >= 0x03000000
  static struct PyModuleDef SWIG_module = {
# if PY_VERSION_HEX >= 0x03020000
    PyModuleDef_HEAD_INIT,
# else
    {
      PyObject_HEAD_INIT(NULL)
      NULL, /* m_init */
      0,    /* m_index */
      NULL, /* m_copy */
    },
# endif
    (char *) SWIG_name,
    NULL,
    -1,
    SwigMethods,
    NULL,
    NULL,
    NULL,
    NULL
  };
#endif
  
#if defined(SWIGPYTHON_BUILTIN)
  static SwigPyClientData SwigPyObject_clientdata = {
    0, 0, 0, 0, 0, 0, 0
  };
  static PyGetSetDef this_getset_def = {
    (char *)"this", &SwigPyBuiltin_ThisClosure, NULL, NULL, NULL
  };
  static SwigPyGetSet thisown_getset_closure = {
    SwigPyObject_own,
    SwigPyObject_own
  };
  static PyGetSetDef thisown_getset_def = {
    (char *)"thisown", SwigPyBuiltin_GetterClosure, SwigPyBuiltin_SetterClosure, NULL, &thisown_getset_closure
  };
  PyTypeObject *builtin_pytype;
  int builtin_base_count;
  swig_type_info *builtin_basetype;
  PyObject *tuple;
  PyGetSetDescrObject *static_getset;
  PyTypeObject *metatype;
  PyTypeObject *swigpyobject;
  SwigPyClientData *cd;
  PyObject *public_interface, *public_symbol;
  PyObject *this_descr;
  PyObject *thisown_descr;
  PyObject *self = 0;
  int i;
  
  (void)builtin_pytype;
  (void)builtin_base_count;
  (void)builtin_basetype;
  (void)tuple;
  (void)static_getset;
  (void)self;
  
  /* Metaclass is used to implement static member variables */
  metatype = SwigPyObjectType();
  assert(metatype);
#endif
  
  /* Fix SwigMethods to carry the callback ptrs when needed */
  SWIG_Python_FixMethods(SwigMethods, swig_const_table, swig_types, swig_type_initial);
  
#if PY_VERSION_HEX >= 0x03000000
  m = PyModule_Create(&SWIG_module);
#else
  m = Py_InitModule((char *) SWIG_name, SwigMethods);
#endif
  
  md = d = PyModule_GetDict(m);
  (void)md;
  
  SWIG_InitializeModule(0);
  
#ifdef SWIGPYTHON_BUILTIN
  swigpyobject = SwigPyObject_TypeOnce();
  
  SwigPyObject_stype = SWIG_MangledTypeQuery("_p_SwigPyObject");
  assert(SwigPyObject_stype);
  cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
  if (!cd) {
    SwigPyObject_stype->clientdata = &SwigPyObject_clientdata;
    SwigPyObject_clientdata.pytype = swigpyobject;
  } else if (swigpyobject->tp_basicsize != cd->pytype->tp_basicsize) {
    PyErr_SetString(PyExc_RuntimeError, "Import error: attempted to load two incompatible swig-generated modules.");
# if PY_VERSION_HEX >= 0x03000000
    return NULL;
# else
    return;
# endif
  }
  
  /* All objects have a 'this' attribute */
  this_descr = PyDescr_NewGetSet(SwigPyObject_type(), &this_getset_def);
  (void)this_descr;
  
  /* All objects have a 'thisown' attribute */
  thisown_descr = PyDescr_NewGetSet(SwigPyObject_type(), &thisown_getset_def);
  (void)thisown_descr;
  
  public_interface = PyList_New(0);
  public_symbol = 0;
  (void)public_symbol;
  
  PyDict_SetItemString(md, "__all__", public_interface);
  Py_DECREF(public_interface);
  for (i = 0; SwigMethods[i].ml_name != NULL; ++i)
  SwigPyBuiltin_AddPublicSymbol(public_interface, SwigMethods[i].ml_name);
  for (i = 0; swig_const_table[i].name != 0; ++i)
  SwigPyBuiltin_AddPublicSymbol(public_interface, swig_const_table[i].name);
#endif
  
  SWIG_InstallConstants(d,swig_const_table);
  
  SWIG_Python_SetConstant(d, "BUILD_REVISION",SWIG_FromCharPtr("0000000"));
  SWIG_Python_SetConstant(d, "BUILD_TIMESTAMP",SWIG_FromCharPtr("<none>"));
  SWIG_Python_SetConstant(d, "ENABLE_UISERVER",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "GPGME_LIBASSUAN_VERSION",SWIG_FromCharPtr(""));
  SWIG_Python_SetConstant(d, "HAVE_ARGP_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_DECL_TTYNAME_R",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_DLFCN_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_ERROR_T",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_FSEEKO",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_GETEGID",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_GETGID",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_INTTYPES_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_LOCALE_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_MEMORY_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_POSIXDECL_TTYNAME_R",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_SETENV",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_SETLOCALE",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_STDINT_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_STDLIB_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_STPCPY",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_STRINGS_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_STRING_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_SYS_SELECT_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_SYS_STAT_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_SYS_TIME_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_SYS_TYPES_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_SYS_UIO_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_THREAD_SAFE_GETENV",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_TIMEGM",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_TLS",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_TTYNAME_R",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_UINTPTR_T",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "HAVE_UNISTD_H",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "LT_OBJDIR",SWIG_FromCharPtr(".libs/"));
  SWIG_Python_SetConstant(d, "PACKAGE",SWIG_FromCharPtr("gpgme"));
  SWIG_Python_SetConstant(d, "PACKAGE_BUGREPORT",SWIG_FromCharPtr("https://bugs.gnupg.org"));
  SWIG_Python_SetConstant(d, "PACKAGE_NAME",SWIG_FromCharPtr("gpgme"));
  SWIG_Python_SetConstant(d, "PACKAGE_STRING",SWIG_FromCharPtr("gpgme 1.13.1-unknown"));
  SWIG_Python_SetConstant(d, "PACKAGE_TARNAME",SWIG_FromCharPtr("gpgme"));
  SWIG_Python_SetConstant(d, "PACKAGE_URL",SWIG_FromCharPtr(""));
  SWIG_Python_SetConstant(d, "PACKAGE_VERSION",SWIG_FromCharPtr("1.13.1-unknown"));
  SWIG_Python_SetConstant(d, "PATHSEP_C",SWIG_From_char((char)(':')));
  SWIG_Python_SetConstant(d, "DIRSEP_C",SWIG_From_char((char)('/')));
  SWIG_Python_SetConstant(d, "DIRSEP_S",SWIG_FromCharPtr("/"));
  SWIG_Python_SetConstant(d, "SIZEOF_UNSIGNED_INT",SWIG_From_int((int)(4)));
  SWIG_Python_SetConstant(d, "STDC_HEADERS",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "USE_DESCRIPTOR_PASSING",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "USE_LINUX_GETDENTS",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "_ALL_SOURCE",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "_GNU_SOURCE",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "_POSIX_PTHREAD_SEMANTICS",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "_TANDEM_SOURCE",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "__EXTENSIONS__",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "VERSION",SWIG_FromCharPtr("1.13.1-unknown"));
  SWIG_Python_SetConstant(d, "_DARWIN_USE_64_BIT_INODE",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "_REENTRANT",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENABLE_ERRNO_MACROS",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "CRIGHTBLURB",SWIG_FromCharPtr("Copyright (C) 2000 Werner Koch\nCopyright (C) 2001--2018 g10 Code GmbH\n"));
  SWIG_Python_SetConstant(d, "GPGME_VERSION",SWIG_FromCharPtr("1.13.1-unknown"));
  SWIG_Python_SetConstant(d, "GPGME_VERSION_NUMBER",SWIG_From_int((int)(0x010d01)));
  SWIG_Python_SetConstant(d, "_GPGME_OBSOLETE_SOME_SYMBOLS",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_ENCODING_NONE",SWIG_From_int((int)(GPGME_DATA_ENCODING_NONE)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_ENCODING_BINARY",SWIG_From_int((int)(GPGME_DATA_ENCODING_BINARY)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_ENCODING_BASE64",SWIG_From_int((int)(GPGME_DATA_ENCODING_BASE64)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_ENCODING_ARMOR",SWIG_From_int((int)(GPGME_DATA_ENCODING_ARMOR)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_ENCODING_URL",SWIG_From_int((int)(GPGME_DATA_ENCODING_URL)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_ENCODING_URLESC",SWIG_From_int((int)(GPGME_DATA_ENCODING_URLESC)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_ENCODING_URL0",SWIG_From_int((int)(GPGME_DATA_ENCODING_URL0)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_ENCODING_MIME",SWIG_From_int((int)(GPGME_DATA_ENCODING_MIME)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_INVALID",SWIG_From_int((int)(GPGME_DATA_TYPE_INVALID)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_UNKNOWN",SWIG_From_int((int)(GPGME_DATA_TYPE_UNKNOWN)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_PGP_SIGNED",SWIG_From_int((int)(GPGME_DATA_TYPE_PGP_SIGNED)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_PGP_ENCRYPTED",SWIG_From_int((int)(GPGME_DATA_TYPE_PGP_ENCRYPTED)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_PGP_OTHER",SWIG_From_int((int)(GPGME_DATA_TYPE_PGP_OTHER)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_PGP_KEY",SWIG_From_int((int)(GPGME_DATA_TYPE_PGP_KEY)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_PGP_SIGNATURE",SWIG_From_int((int)(GPGME_DATA_TYPE_PGP_SIGNATURE)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_CMS_SIGNED",SWIG_From_int((int)(GPGME_DATA_TYPE_CMS_SIGNED)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_CMS_ENCRYPTED",SWIG_From_int((int)(GPGME_DATA_TYPE_CMS_ENCRYPTED)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_CMS_OTHER",SWIG_From_int((int)(GPGME_DATA_TYPE_CMS_OTHER)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_X509_CERT",SWIG_From_int((int)(GPGME_DATA_TYPE_X509_CERT)));
  SWIG_Python_SetConstant(d, "GPGME_DATA_TYPE_PKCS12",SWIG_From_int((int)(GPGME_DATA_TYPE_PKCS12)));
  SWIG_Python_SetConstant(d, "GPGME_PK_RSA",SWIG_From_int((int)(GPGME_PK_RSA)));
  SWIG_Python_SetConstant(d, "GPGME_PK_RSA_E",SWIG_From_int((int)(GPGME_PK_RSA_E)));
  SWIG_Python_SetConstant(d, "GPGME_PK_RSA_S",SWIG_From_int((int)(GPGME_PK_RSA_S)));
  SWIG_Python_SetConstant(d, "GPGME_PK_ELG_E",SWIG_From_int((int)(GPGME_PK_ELG_E)));
  SWIG_Python_SetConstant(d, "GPGME_PK_DSA",SWIG_From_int((int)(GPGME_PK_DSA)));
  SWIG_Python_SetConstant(d, "GPGME_PK_ECC",SWIG_From_int((int)(GPGME_PK_ECC)));
  SWIG_Python_SetConstant(d, "GPGME_PK_ELG",SWIG_From_int((int)(GPGME_PK_ELG)));
  SWIG_Python_SetConstant(d, "GPGME_PK_ECDSA",SWIG_From_int((int)(GPGME_PK_ECDSA)));
  SWIG_Python_SetConstant(d, "GPGME_PK_ECDH",SWIG_From_int((int)(GPGME_PK_ECDH)));
  SWIG_Python_SetConstant(d, "GPGME_PK_EDDSA",SWIG_From_int((int)(GPGME_PK_EDDSA)));
  SWIG_Python_SetConstant(d, "GPGME_MD_NONE",SWIG_From_int((int)(GPGME_MD_NONE)));
  SWIG_Python_SetConstant(d, "GPGME_MD_MD5",SWIG_From_int((int)(GPGME_MD_MD5)));
  SWIG_Python_SetConstant(d, "GPGME_MD_SHA1",SWIG_From_int((int)(GPGME_MD_SHA1)));
  SWIG_Python_SetConstant(d, "GPGME_MD_RMD160",SWIG_From_int((int)(GPGME_MD_RMD160)));
  SWIG_Python_SetConstant(d, "GPGME_MD_MD2",SWIG_From_int((int)(GPGME_MD_MD2)));
  SWIG_Python_SetConstant(d, "GPGME_MD_TIGER",SWIG_From_int((int)(GPGME_MD_TIGER)));
  SWIG_Python_SetConstant(d, "GPGME_MD_HAVAL",SWIG_From_int((int)(GPGME_MD_HAVAL)));
  SWIG_Python_SetConstant(d, "GPGME_MD_SHA256",SWIG_From_int((int)(GPGME_MD_SHA256)));
  SWIG_Python_SetConstant(d, "GPGME_MD_SHA384",SWIG_From_int((int)(GPGME_MD_SHA384)));
  SWIG_Python_SetConstant(d, "GPGME_MD_SHA512",SWIG_From_int((int)(GPGME_MD_SHA512)));
  SWIG_Python_SetConstant(d, "GPGME_MD_SHA224",SWIG_From_int((int)(GPGME_MD_SHA224)));
  SWIG_Python_SetConstant(d, "GPGME_MD_MD4",SWIG_From_int((int)(GPGME_MD_MD4)));
  SWIG_Python_SetConstant(d, "GPGME_MD_CRC32",SWIG_From_int((int)(GPGME_MD_CRC32)));
  SWIG_Python_SetConstant(d, "GPGME_MD_CRC32_RFC1510",SWIG_From_int((int)(GPGME_MD_CRC32_RFC1510)));
  SWIG_Python_SetConstant(d, "GPGME_MD_CRC24_RFC2440",SWIG_From_int((int)(GPGME_MD_CRC24_RFC2440)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_MODE_NORMAL",SWIG_From_int((int)(GPGME_SIG_MODE_NORMAL)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_MODE_DETACH",SWIG_From_int((int)(GPGME_SIG_MODE_DETACH)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_MODE_CLEAR",SWIG_From_int((int)(GPGME_SIG_MODE_CLEAR)));
  SWIG_Python_SetConstant(d, "GPGME_VALIDITY_UNKNOWN",SWIG_From_int((int)(GPGME_VALIDITY_UNKNOWN)));
  SWIG_Python_SetConstant(d, "GPGME_VALIDITY_UNDEFINED",SWIG_From_int((int)(GPGME_VALIDITY_UNDEFINED)));
  SWIG_Python_SetConstant(d, "GPGME_VALIDITY_NEVER",SWIG_From_int((int)(GPGME_VALIDITY_NEVER)));
  SWIG_Python_SetConstant(d, "GPGME_VALIDITY_MARGINAL",SWIG_From_int((int)(GPGME_VALIDITY_MARGINAL)));
  SWIG_Python_SetConstant(d, "GPGME_VALIDITY_FULL",SWIG_From_int((int)(GPGME_VALIDITY_FULL)));
  SWIG_Python_SetConstant(d, "GPGME_VALIDITY_ULTIMATE",SWIG_From_int((int)(GPGME_VALIDITY_ULTIMATE)));
  SWIG_Python_SetConstant(d, "GPGME_TOFU_POLICY_NONE",SWIG_From_int((int)(GPGME_TOFU_POLICY_NONE)));
  SWIG_Python_SetConstant(d, "GPGME_TOFU_POLICY_AUTO",SWIG_From_int((int)(GPGME_TOFU_POLICY_AUTO)));
  SWIG_Python_SetConstant(d, "GPGME_TOFU_POLICY_GOOD",SWIG_From_int((int)(GPGME_TOFU_POLICY_GOOD)));
  SWIG_Python_SetConstant(d, "GPGME_TOFU_POLICY_UNKNOWN",SWIG_From_int((int)(GPGME_TOFU_POLICY_UNKNOWN)));
  SWIG_Python_SetConstant(d, "GPGME_TOFU_POLICY_BAD",SWIG_From_int((int)(GPGME_TOFU_POLICY_BAD)));
  SWIG_Python_SetConstant(d, "GPGME_TOFU_POLICY_ASK",SWIG_From_int((int)(GPGME_TOFU_POLICY_ASK)));
  SWIG_Python_SetConstant(d, "GPGME_KEYORG_UNKNOWN",SWIG_From_int((int)(GPGME_KEYORG_UNKNOWN)));
  SWIG_Python_SetConstant(d, "GPGME_KEYORG_KS",SWIG_From_int((int)(GPGME_KEYORG_KS)));
  SWIG_Python_SetConstant(d, "GPGME_KEYORG_DANE",SWIG_From_int((int)(GPGME_KEYORG_DANE)));
  SWIG_Python_SetConstant(d, "GPGME_KEYORG_WKD",SWIG_From_int((int)(GPGME_KEYORG_WKD)));
  SWIG_Python_SetConstant(d, "GPGME_KEYORG_URL",SWIG_From_int((int)(GPGME_KEYORG_URL)));
  SWIG_Python_SetConstant(d, "GPGME_KEYORG_FILE",SWIG_From_int((int)(GPGME_KEYORG_FILE)));
  SWIG_Python_SetConstant(d, "GPGME_KEYORG_SELF",SWIG_From_int((int)(GPGME_KEYORG_SELF)));
  SWIG_Python_SetConstant(d, "GPGME_KEYORG_OTHER",SWIG_From_int((int)(GPGME_KEYORG_OTHER)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_OpenPGP",SWIG_From_int((int)(GPGME_PROTOCOL_OpenPGP)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_CMS",SWIG_From_int((int)(GPGME_PROTOCOL_CMS)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_GPGCONF",SWIG_From_int((int)(GPGME_PROTOCOL_GPGCONF)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_ASSUAN",SWIG_From_int((int)(GPGME_PROTOCOL_ASSUAN)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_G13",SWIG_From_int((int)(GPGME_PROTOCOL_G13)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_UISERVER",SWIG_From_int((int)(GPGME_PROTOCOL_UISERVER)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_SPAWN",SWIG_From_int((int)(GPGME_PROTOCOL_SPAWN)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_DEFAULT",SWIG_From_int((int)(GPGME_PROTOCOL_DEFAULT)));
  SWIG_Python_SetConstant(d, "GPGME_PROTOCOL_UNKNOWN",SWIG_From_int((int)(GPGME_PROTOCOL_UNKNOWN)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_LOCAL",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_EXTERN",SWIG_From_int((int)(2)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_SIGS",SWIG_From_int((int)(4)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_SIG_NOTATIONS",SWIG_From_int((int)(8)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_WITH_SECRET",SWIG_From_int((int)(16)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_WITH_TOFU",SWIG_From_int((int)(32)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_EPHEMERAL",SWIG_From_int((int)(128)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_VALIDATE",SWIG_From_int((int)(256)));
  SWIG_Python_SetConstant(d, "GPGME_KEYLIST_MODE_LOCATE",SWIG_From_int((int)((1|2))));
  SWIG_Python_SetConstant(d, "GPGME_PINENTRY_MODE_DEFAULT",SWIG_From_int((int)(GPGME_PINENTRY_MODE_DEFAULT)));
  SWIG_Python_SetConstant(d, "GPGME_PINENTRY_MODE_ASK",SWIG_From_int((int)(GPGME_PINENTRY_MODE_ASK)));
  SWIG_Python_SetConstant(d, "GPGME_PINENTRY_MODE_CANCEL",SWIG_From_int((int)(GPGME_PINENTRY_MODE_CANCEL)));
  SWIG_Python_SetConstant(d, "GPGME_PINENTRY_MODE_ERROR",SWIG_From_int((int)(GPGME_PINENTRY_MODE_ERROR)));
  SWIG_Python_SetConstant(d, "GPGME_PINENTRY_MODE_LOOPBACK",SWIG_From_int((int)(GPGME_PINENTRY_MODE_LOOPBACK)));
  SWIG_Python_SetConstant(d, "GPGME_EXPORT_MODE_EXTERN",SWIG_From_int((int)(2)));
  SWIG_Python_SetConstant(d, "GPGME_EXPORT_MODE_MINIMAL",SWIG_From_int((int)(4)));
  SWIG_Python_SetConstant(d, "GPGME_EXPORT_MODE_SECRET",SWIG_From_int((int)(16)));
  SWIG_Python_SetConstant(d, "GPGME_EXPORT_MODE_RAW",SWIG_From_int((int)(32)));
  SWIG_Python_SetConstant(d, "GPGME_EXPORT_MODE_PKCS12",SWIG_From_int((int)(64)));
  SWIG_Python_SetConstant(d, "GPGME_EXPORT_MODE_NOUID",SWIG_From_int((int)(128)));
  SWIG_Python_SetConstant(d, "GPGME_AUDITLOG_DEFAULT",SWIG_From_int((int)(0)));
  SWIG_Python_SetConstant(d, "GPGME_AUDITLOG_HTML",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "GPGME_AUDITLOG_DIAG",SWIG_From_int((int)(2)));
  SWIG_Python_SetConstant(d, "GPGME_AUDITLOG_WITH_HELP",SWIG_From_int((int)(128)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_NOTATION_HUMAN_READABLE",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_NOTATION_CRITICAL",SWIG_From_int((int)(2)));
  SWIG_Python_SetConstant(d, "GPGME_INCLUDE_CERTS_DEFAULT",SWIG_From_int((int)(-256)));
  SWIG_Python_SetConstant(d, "GPGME_EVENT_START",SWIG_From_int((int)(GPGME_EVENT_START)));
  SWIG_Python_SetConstant(d, "GPGME_EVENT_DONE",SWIG_From_int((int)(GPGME_EVENT_DONE)));
  SWIG_Python_SetConstant(d, "GPGME_EVENT_NEXT_KEY",SWIG_From_int((int)(GPGME_EVENT_NEXT_KEY)));
  SWIG_Python_SetConstant(d, "GPGME_EVENT_NEXT_TRUSTITEM",SWIG_From_int((int)(GPGME_EVENT_NEXT_TRUSTITEM)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_ALWAYS_TRUST",SWIG_From_int((int)(GPGME_ENCRYPT_ALWAYS_TRUST)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_NO_ENCRYPT_TO",SWIG_From_int((int)(GPGME_ENCRYPT_NO_ENCRYPT_TO)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_PREPARE",SWIG_From_int((int)(GPGME_ENCRYPT_PREPARE)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_EXPECT_SIGN",SWIG_From_int((int)(GPGME_ENCRYPT_EXPECT_SIGN)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_NO_COMPRESS",SWIG_From_int((int)(GPGME_ENCRYPT_NO_COMPRESS)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_SYMMETRIC",SWIG_From_int((int)(GPGME_ENCRYPT_SYMMETRIC)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_THROW_KEYIDS",SWIG_From_int((int)(GPGME_ENCRYPT_THROW_KEYIDS)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_WRAP",SWIG_From_int((int)(GPGME_ENCRYPT_WRAP)));
  SWIG_Python_SetConstant(d, "GPGME_ENCRYPT_WANT_ADDRESS",SWIG_From_int((int)(GPGME_ENCRYPT_WANT_ADDRESS)));
  SWIG_Python_SetConstant(d, "GPGME_DECRYPT_VERIFY",SWIG_From_int((int)(GPGME_DECRYPT_VERIFY)));
  SWIG_Python_SetConstant(d, "GPGME_DECRYPT_UNWRAP",SWIG_From_int((int)(GPGME_DECRYPT_UNWRAP)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_VALID",SWIG_From_int((int)(GPGME_SIGSUM_VALID)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_GREEN",SWIG_From_int((int)(GPGME_SIGSUM_GREEN)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_RED",SWIG_From_int((int)(GPGME_SIGSUM_RED)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_KEY_REVOKED",SWIG_From_int((int)(GPGME_SIGSUM_KEY_REVOKED)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_KEY_EXPIRED",SWIG_From_int((int)(GPGME_SIGSUM_KEY_EXPIRED)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_SIG_EXPIRED",SWIG_From_int((int)(GPGME_SIGSUM_SIG_EXPIRED)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_KEY_MISSING",SWIG_From_int((int)(GPGME_SIGSUM_KEY_MISSING)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_CRL_MISSING",SWIG_From_int((int)(GPGME_SIGSUM_CRL_MISSING)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_CRL_TOO_OLD",SWIG_From_int((int)(GPGME_SIGSUM_CRL_TOO_OLD)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_BAD_POLICY",SWIG_From_int((int)(GPGME_SIGSUM_BAD_POLICY)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_SYS_ERROR",SWIG_From_int((int)(GPGME_SIGSUM_SYS_ERROR)));
  SWIG_Python_SetConstant(d, "GPGME_SIGSUM_TOFU_CONFLICT",SWIG_From_int((int)(GPGME_SIGSUM_TOFU_CONFLICT)));
  SWIG_Python_SetConstant(d, "GPGME_IMPORT_NEW",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "GPGME_IMPORT_UID",SWIG_From_int((int)(2)));
  SWIG_Python_SetConstant(d, "GPGME_IMPORT_SIG",SWIG_From_int((int)(4)));
  SWIG_Python_SetConstant(d, "GPGME_IMPORT_SUBKEY",SWIG_From_int((int)(8)));
  SWIG_Python_SetConstant(d, "GPGME_IMPORT_SECRET",SWIG_From_int((int)(16)));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_SIGN",SWIG_From_int((int)((1 << 0))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_ENCR",SWIG_From_int((int)((1 << 1))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_CERT",SWIG_From_int((int)((1 << 2))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_AUTH",SWIG_From_int((int)((1 << 3))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_NOPASSWD",SWIG_From_int((int)((1 << 7))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_SELFSIGNED",SWIG_From_int((int)((1 << 8))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_NOSTORE",SWIG_From_int((int)((1 << 9))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_WANTPUB",SWIG_From_int((int)((1 << 10))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_WANTSEC",SWIG_From_int((int)((1 << 11))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_FORCE",SWIG_From_int((int)((1 << 12))));
  SWIG_Python_SetConstant(d, "GPGME_CREATE_NOEXPIRE",SWIG_From_int((int)((1 << 13))));
  SWIG_Python_SetConstant(d, "GPGME_DELETE_ALLOW_SECRET",SWIG_From_int((int)((1 << 0))));
  SWIG_Python_SetConstant(d, "GPGME_DELETE_FORCE",SWIG_From_int((int)((1 << 1))));
  SWIG_Python_SetConstant(d, "GPGME_KEYSIGN_LOCAL",SWIG_From_int((int)((1 << 7))));
  SWIG_Python_SetConstant(d, "GPGME_KEYSIGN_LFSEP",SWIG_From_int((int)((1 << 8))));
  SWIG_Python_SetConstant(d, "GPGME_KEYSIGN_NOEXPIRE",SWIG_From_int((int)((1 << 9))));
  SWIG_Python_SetConstant(d, "GPGME_INTERACT_CARD",SWIG_From_int((int)((1 << 0))));
  SWIG_Python_SetConstant(d, "GPGME_SPAWN_DETACHED",SWIG_From_int((int)(1)));
  SWIG_Python_SetConstant(d, "GPGME_SPAWN_ALLOW_SET_FG",SWIG_From_int((int)(2)));
  SWIG_Python_SetConstant(d, "GPGME_SPAWN_SHOW_WINDOW",SWIG_From_int((int)(4)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_BASIC",SWIG_From_int((int)(GPGME_CONF_BASIC)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_ADVANCED",SWIG_From_int((int)(GPGME_CONF_ADVANCED)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_EXPERT",SWIG_From_int((int)(GPGME_CONF_EXPERT)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_INVISIBLE",SWIG_From_int((int)(GPGME_CONF_INVISIBLE)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_INTERNAL",SWIG_From_int((int)(GPGME_CONF_INTERNAL)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_NONE",SWIG_From_int((int)(GPGME_CONF_NONE)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_STRING",SWIG_From_int((int)(GPGME_CONF_STRING)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_INT32",SWIG_From_int((int)(GPGME_CONF_INT32)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_UINT32",SWIG_From_int((int)(GPGME_CONF_UINT32)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_FILENAME",SWIG_From_int((int)(GPGME_CONF_FILENAME)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_LDAP_SERVER",SWIG_From_int((int)(GPGME_CONF_LDAP_SERVER)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_KEY_FPR",SWIG_From_int((int)(GPGME_CONF_KEY_FPR)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_PUB_KEY",SWIG_From_int((int)(GPGME_CONF_PUB_KEY)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_SEC_KEY",SWIG_From_int((int)(GPGME_CONF_SEC_KEY)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_ALIAS_LIST",SWIG_From_int((int)(GPGME_CONF_ALIAS_LIST)));
  SWIG_Python_SetConstant(d, "GPGME_CONF_GROUP",SWIG_From_int((int)((1 << 0))));
  SWIG_Python_SetConstant(d, "GPGME_CONF_OPTIONAL",SWIG_From_int((int)((1 << 1))));
  SWIG_Python_SetConstant(d, "GPGME_CONF_LIST",SWIG_From_int((int)((1 << 2))));
  SWIG_Python_SetConstant(d, "GPGME_CONF_RUNTIME",SWIG_From_int((int)((1 << 3))));
  SWIG_Python_SetConstant(d, "GPGME_CONF_DEFAULT",SWIG_From_int((int)((1 << 4))));
  SWIG_Python_SetConstant(d, "GPGME_CONF_DEFAULT_DESC",SWIG_From_int((int)((1 << 5))));
  SWIG_Python_SetConstant(d, "GPGME_CONF_NO_ARG_DESC",SWIG_From_int((int)((1 << 6))));
  SWIG_Python_SetConstant(d, "GPGME_CONF_NO_CHANGE",SWIG_From_int((int)((1 << 7))));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_EOF",SWIG_From_int((int)(GPGME_STATUS_EOF)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_ENTER",SWIG_From_int((int)(GPGME_STATUS_ENTER)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_LEAVE",SWIG_From_int((int)(GPGME_STATUS_LEAVE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_ABORT",SWIG_From_int((int)(GPGME_STATUS_ABORT)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_GOODSIG",SWIG_From_int((int)(GPGME_STATUS_GOODSIG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BADSIG",SWIG_From_int((int)(GPGME_STATUS_BADSIG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_ERRSIG",SWIG_From_int((int)(GPGME_STATUS_ERRSIG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BADARMOR",SWIG_From_int((int)(GPGME_STATUS_BADARMOR)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_RSA_OR_IDEA",SWIG_From_int((int)(GPGME_STATUS_RSA_OR_IDEA)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_KEYEXPIRED",SWIG_From_int((int)(GPGME_STATUS_KEYEXPIRED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_KEYREVOKED",SWIG_From_int((int)(GPGME_STATUS_KEYREVOKED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TRUST_UNDEFINED",SWIG_From_int((int)(GPGME_STATUS_TRUST_UNDEFINED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TRUST_NEVER",SWIG_From_int((int)(GPGME_STATUS_TRUST_NEVER)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TRUST_MARGINAL",SWIG_From_int((int)(GPGME_STATUS_TRUST_MARGINAL)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TRUST_FULLY",SWIG_From_int((int)(GPGME_STATUS_TRUST_FULLY)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TRUST_ULTIMATE",SWIG_From_int((int)(GPGME_STATUS_TRUST_ULTIMATE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SHM_INFO",SWIG_From_int((int)(GPGME_STATUS_SHM_INFO)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SHM_GET",SWIG_From_int((int)(GPGME_STATUS_SHM_GET)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SHM_GET_BOOL",SWIG_From_int((int)(GPGME_STATUS_SHM_GET_BOOL)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SHM_GET_HIDDEN",SWIG_From_int((int)(GPGME_STATUS_SHM_GET_HIDDEN)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NEED_PASSPHRASE",SWIG_From_int((int)(GPGME_STATUS_NEED_PASSPHRASE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_VALIDSIG",SWIG_From_int((int)(GPGME_STATUS_VALIDSIG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SIG_ID",SWIG_From_int((int)(GPGME_STATUS_SIG_ID)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_ENC_TO",SWIG_From_int((int)(GPGME_STATUS_ENC_TO)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NODATA",SWIG_From_int((int)(GPGME_STATUS_NODATA)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BAD_PASSPHRASE",SWIG_From_int((int)(GPGME_STATUS_BAD_PASSPHRASE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NO_PUBKEY",SWIG_From_int((int)(GPGME_STATUS_NO_PUBKEY)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NO_SECKEY",SWIG_From_int((int)(GPGME_STATUS_NO_SECKEY)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NEED_PASSPHRASE_SYM",SWIG_From_int((int)(GPGME_STATUS_NEED_PASSPHRASE_SYM)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_DECRYPTION_FAILED",SWIG_From_int((int)(GPGME_STATUS_DECRYPTION_FAILED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_DECRYPTION_OKAY",SWIG_From_int((int)(GPGME_STATUS_DECRYPTION_OKAY)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_MISSING_PASSPHRASE",SWIG_From_int((int)(GPGME_STATUS_MISSING_PASSPHRASE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_GOOD_PASSPHRASE",SWIG_From_int((int)(GPGME_STATUS_GOOD_PASSPHRASE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_GOODMDC",SWIG_From_int((int)(GPGME_STATUS_GOODMDC)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BADMDC",SWIG_From_int((int)(GPGME_STATUS_BADMDC)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_ERRMDC",SWIG_From_int((int)(GPGME_STATUS_ERRMDC)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_IMPORTED",SWIG_From_int((int)(GPGME_STATUS_IMPORTED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_IMPORT_OK",SWIG_From_int((int)(GPGME_STATUS_IMPORT_OK)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_IMPORT_PROBLEM",SWIG_From_int((int)(GPGME_STATUS_IMPORT_PROBLEM)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_IMPORT_RES",SWIG_From_int((int)(GPGME_STATUS_IMPORT_RES)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_FILE_START",SWIG_From_int((int)(GPGME_STATUS_FILE_START)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_FILE_DONE",SWIG_From_int((int)(GPGME_STATUS_FILE_DONE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_FILE_ERROR",SWIG_From_int((int)(GPGME_STATUS_FILE_ERROR)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BEGIN_DECRYPTION",SWIG_From_int((int)(GPGME_STATUS_BEGIN_DECRYPTION)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_END_DECRYPTION",SWIG_From_int((int)(GPGME_STATUS_END_DECRYPTION)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BEGIN_ENCRYPTION",SWIG_From_int((int)(GPGME_STATUS_BEGIN_ENCRYPTION)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_END_ENCRYPTION",SWIG_From_int((int)(GPGME_STATUS_END_ENCRYPTION)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_DELETE_PROBLEM",SWIG_From_int((int)(GPGME_STATUS_DELETE_PROBLEM)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_GET_BOOL",SWIG_From_int((int)(GPGME_STATUS_GET_BOOL)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_GET_LINE",SWIG_From_int((int)(GPGME_STATUS_GET_LINE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_GET_HIDDEN",SWIG_From_int((int)(GPGME_STATUS_GET_HIDDEN)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_GOT_IT",SWIG_From_int((int)(GPGME_STATUS_GOT_IT)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_PROGRESS",SWIG_From_int((int)(GPGME_STATUS_PROGRESS)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SIG_CREATED",SWIG_From_int((int)(GPGME_STATUS_SIG_CREATED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SESSION_KEY",SWIG_From_int((int)(GPGME_STATUS_SESSION_KEY)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NOTATION_NAME",SWIG_From_int((int)(GPGME_STATUS_NOTATION_NAME)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NOTATION_DATA",SWIG_From_int((int)(GPGME_STATUS_NOTATION_DATA)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_POLICY_URL",SWIG_From_int((int)(GPGME_STATUS_POLICY_URL)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BEGIN_STREAM",SWIG_From_int((int)(GPGME_STATUS_BEGIN_STREAM)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_END_STREAM",SWIG_From_int((int)(GPGME_STATUS_END_STREAM)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_KEY_CREATED",SWIG_From_int((int)(GPGME_STATUS_KEY_CREATED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_USERID_HINT",SWIG_From_int((int)(GPGME_STATUS_USERID_HINT)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_UNEXPECTED",SWIG_From_int((int)(GPGME_STATUS_UNEXPECTED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_INV_RECP",SWIG_From_int((int)(GPGME_STATUS_INV_RECP)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NO_RECP",SWIG_From_int((int)(GPGME_STATUS_NO_RECP)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_ALREADY_SIGNED",SWIG_From_int((int)(GPGME_STATUS_ALREADY_SIGNED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SIGEXPIRED",SWIG_From_int((int)(GPGME_STATUS_SIGEXPIRED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_EXPSIG",SWIG_From_int((int)(GPGME_STATUS_EXPSIG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_EXPKEYSIG",SWIG_From_int((int)(GPGME_STATUS_EXPKEYSIG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TRUNCATED",SWIG_From_int((int)(GPGME_STATUS_TRUNCATED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_ERROR",SWIG_From_int((int)(GPGME_STATUS_ERROR)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NEWSIG",SWIG_From_int((int)(GPGME_STATUS_NEWSIG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_REVKEYSIG",SWIG_From_int((int)(GPGME_STATUS_REVKEYSIG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SIG_SUBPACKET",SWIG_From_int((int)(GPGME_STATUS_SIG_SUBPACKET)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NEED_PASSPHRASE_PIN",SWIG_From_int((int)(GPGME_STATUS_NEED_PASSPHRASE_PIN)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SC_OP_FAILURE",SWIG_From_int((int)(GPGME_STATUS_SC_OP_FAILURE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SC_OP_SUCCESS",SWIG_From_int((int)(GPGME_STATUS_SC_OP_SUCCESS)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_CARDCTRL",SWIG_From_int((int)(GPGME_STATUS_CARDCTRL)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BACKUP_KEY_CREATED",SWIG_From_int((int)(GPGME_STATUS_BACKUP_KEY_CREATED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_PKA_TRUST_BAD",SWIG_From_int((int)(GPGME_STATUS_PKA_TRUST_BAD)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_PKA_TRUST_GOOD",SWIG_From_int((int)(GPGME_STATUS_PKA_TRUST_GOOD)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_PLAINTEXT",SWIG_From_int((int)(GPGME_STATUS_PLAINTEXT)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_INV_SGNR",SWIG_From_int((int)(GPGME_STATUS_INV_SGNR)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NO_SGNR",SWIG_From_int((int)(GPGME_STATUS_NO_SGNR)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_SUCCESS",SWIG_From_int((int)(GPGME_STATUS_SUCCESS)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_DECRYPTION_INFO",SWIG_From_int((int)(GPGME_STATUS_DECRYPTION_INFO)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_PLAINTEXT_LENGTH",SWIG_From_int((int)(GPGME_STATUS_PLAINTEXT_LENGTH)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_MOUNTPOINT",SWIG_From_int((int)(GPGME_STATUS_MOUNTPOINT)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_PINENTRY_LAUNCHED",SWIG_From_int((int)(GPGME_STATUS_PINENTRY_LAUNCHED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_ATTRIBUTE",SWIG_From_int((int)(GPGME_STATUS_ATTRIBUTE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_BEGIN_SIGNING",SWIG_From_int((int)(GPGME_STATUS_BEGIN_SIGNING)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_KEY_NOT_CREATED",SWIG_From_int((int)(GPGME_STATUS_KEY_NOT_CREATED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_INQUIRE_MAXLEN",SWIG_From_int((int)(GPGME_STATUS_INQUIRE_MAXLEN)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_FAILURE",SWIG_From_int((int)(GPGME_STATUS_FAILURE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_KEY_CONSIDERED",SWIG_From_int((int)(GPGME_STATUS_KEY_CONSIDERED)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TOFU_USER",SWIG_From_int((int)(GPGME_STATUS_TOFU_USER)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TOFU_STATS",SWIG_From_int((int)(GPGME_STATUS_TOFU_STATS)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_TOFU_STATS_LONG",SWIG_From_int((int)(GPGME_STATUS_TOFU_STATS_LONG)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_NOTATION_FLAGS",SWIG_From_int((int)(GPGME_STATUS_NOTATION_FLAGS)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_DECRYPTION_COMPLIANCE_MODE",SWIG_From_int((int)(GPGME_STATUS_DECRYPTION_COMPLIANCE_MODE)));
  SWIG_Python_SetConstant(d, "GPGME_STATUS_VERIFICATION_COMPLIANCE_MODE",SWIG_From_int((int)(GPGME_STATUS_VERIFICATION_COMPLIANCE_MODE)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_NONE",SWIG_From_int((int)(GPGME_SIG_STAT_NONE)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_GOOD",SWIG_From_int((int)(GPGME_SIG_STAT_GOOD)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_BAD",SWIG_From_int((int)(GPGME_SIG_STAT_BAD)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_NOKEY",SWIG_From_int((int)(GPGME_SIG_STAT_NOKEY)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_NOSIG",SWIG_From_int((int)(GPGME_SIG_STAT_NOSIG)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_ERROR",SWIG_From_int((int)(GPGME_SIG_STAT_ERROR)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_DIFF",SWIG_From_int((int)(GPGME_SIG_STAT_DIFF)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_GOOD_EXP",SWIG_From_int((int)(GPGME_SIG_STAT_GOOD_EXP)));
  SWIG_Python_SetConstant(d, "GPGME_SIG_STAT_GOOD_EXPKEY",SWIG_From_int((int)(GPGME_SIG_STAT_GOOD_EXPKEY)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_KEYID",SWIG_From_int((int)(GPGME_ATTR_KEYID)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_FPR",SWIG_From_int((int)(GPGME_ATTR_FPR)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_ALGO",SWIG_From_int((int)(GPGME_ATTR_ALGO)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_LEN",SWIG_From_int((int)(GPGME_ATTR_LEN)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_CREATED",SWIG_From_int((int)(GPGME_ATTR_CREATED)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_EXPIRE",SWIG_From_int((int)(GPGME_ATTR_EXPIRE)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_OTRUST",SWIG_From_int((int)(GPGME_ATTR_OTRUST)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_USERID",SWIG_From_int((int)(GPGME_ATTR_USERID)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_NAME",SWIG_From_int((int)(GPGME_ATTR_NAME)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_EMAIL",SWIG_From_int((int)(GPGME_ATTR_EMAIL)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_COMMENT",SWIG_From_int((int)(GPGME_ATTR_COMMENT)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_VALIDITY",SWIG_From_int((int)(GPGME_ATTR_VALIDITY)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_LEVEL",SWIG_From_int((int)(GPGME_ATTR_LEVEL)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_TYPE",SWIG_From_int((int)(GPGME_ATTR_TYPE)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_IS_SECRET",SWIG_From_int((int)(GPGME_ATTR_IS_SECRET)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_KEY_REVOKED",SWIG_From_int((int)(GPGME_ATTR_KEY_REVOKED)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_KEY_INVALID",SWIG_From_int((int)(GPGME_ATTR_KEY_INVALID)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_UID_REVOKED",SWIG_From_int((int)(GPGME_ATTR_UID_REVOKED)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_UID_INVALID",SWIG_From_int((int)(GPGME_ATTR_UID_INVALID)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_KEY_CAPS",SWIG_From_int((int)(GPGME_ATTR_KEY_CAPS)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_CAN_ENCRYPT",SWIG_From_int((int)(GPGME_ATTR_CAN_ENCRYPT)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_CAN_SIGN",SWIG_From_int((int)(GPGME_ATTR_CAN_SIGN)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_CAN_CERTIFY",SWIG_From_int((int)(GPGME_ATTR_CAN_CERTIFY)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_KEY_EXPIRED",SWIG_From_int((int)(GPGME_ATTR_KEY_EXPIRED)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_KEY_DISABLED",SWIG_From_int((int)(GPGME_ATTR_KEY_DISABLED)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_SERIAL",SWIG_From_int((int)(GPGME_ATTR_SERIAL)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_ISSUER",SWIG_From_int((int)(GPGME_ATTR_ISSUER)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_CHAINID",SWIG_From_int((int)(GPGME_ATTR_CHAINID)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_SIG_STATUS",SWIG_From_int((int)(GPGME_ATTR_SIG_STATUS)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_ERRTOK",SWIG_From_int((int)(GPGME_ATTR_ERRTOK)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_SIG_SUMMARY",SWIG_From_int((int)(GPGME_ATTR_SIG_SUMMARY)));
  SWIG_Python_SetConstant(d, "GPGME_ATTR_SIG_CLASS",SWIG_From_int((int)(GPGME_ATTR_SIG_CLASS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_UNKNOWN",SWIG_From_long((long)(GPG_ERR_SOURCE_UNKNOWN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_GCRYPT",SWIG_From_long((long)(GPG_ERR_SOURCE_GCRYPT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_GPG",SWIG_From_long((long)(GPG_ERR_SOURCE_GPG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_GPGSM",SWIG_From_long((long)(GPG_ERR_SOURCE_GPGSM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_GPGAGENT",SWIG_From_long((long)(GPG_ERR_SOURCE_GPGAGENT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_PINENTRY",SWIG_From_long((long)(GPG_ERR_SOURCE_PINENTRY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_SCD",SWIG_From_long((long)(GPG_ERR_SOURCE_SCD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_GPGME",SWIG_From_long((long)(GPG_ERR_SOURCE_GPGME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_KEYBOX",SWIG_From_long((long)(GPG_ERR_SOURCE_KEYBOX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_KSBA",SWIG_From_long((long)(GPG_ERR_SOURCE_KSBA)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_DIRMNGR",SWIG_From_long((long)(GPG_ERR_SOURCE_DIRMNGR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_GSTI",SWIG_From_long((long)(GPG_ERR_SOURCE_GSTI)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_GPA",SWIG_From_long((long)(GPG_ERR_SOURCE_GPA)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_KLEO",SWIG_From_long((long)(GPG_ERR_SOURCE_KLEO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_G13",SWIG_From_long((long)(GPG_ERR_SOURCE_G13)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_ASSUAN",SWIG_From_long((long)(GPG_ERR_SOURCE_ASSUAN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_TLS",SWIG_From_long((long)(GPG_ERR_SOURCE_TLS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_ANY",SWIG_From_long((long)(GPG_ERR_SOURCE_ANY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_USER_1",SWIG_From_long((long)(GPG_ERR_SOURCE_USER_1)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_USER_2",SWIG_From_long((long)(GPG_ERR_SOURCE_USER_2)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_USER_3",SWIG_From_long((long)(GPG_ERR_SOURCE_USER_3)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_USER_4",SWIG_From_long((long)(GPG_ERR_SOURCE_USER_4)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SOURCE_DIM",SWIG_From_long((long)(GPG_ERR_SOURCE_DIM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_ERROR",SWIG_From_long((long)(GPG_ERR_NO_ERROR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_GENERAL",SWIG_From_long((long)(GPG_ERR_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_PACKET",SWIG_From_long((long)(GPG_ERR_UNKNOWN_PACKET)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_VERSION",SWIG_From_long((long)(GPG_ERR_UNKNOWN_VERSION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_PUBKEY_ALGO",SWIG_From_long((long)(GPG_ERR_PUBKEY_ALGO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DIGEST_ALGO",SWIG_From_long((long)(GPG_ERR_DIGEST_ALGO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_PUBKEY",SWIG_From_long((long)(GPG_ERR_BAD_PUBKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_SECKEY",SWIG_From_long((long)(GPG_ERR_BAD_SECKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_SIGNATURE",SWIG_From_long((long)(GPG_ERR_BAD_SIGNATURE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_PUBKEY",SWIG_From_long((long)(GPG_ERR_NO_PUBKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CHECKSUM",SWIG_From_long((long)(GPG_ERR_CHECKSUM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_PASSPHRASE",SWIG_From_long((long)(GPG_ERR_BAD_PASSPHRASE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CIPHER_ALGO",SWIG_From_long((long)(GPG_ERR_CIPHER_ALGO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_KEYRING_OPEN",SWIG_From_long((long)(GPG_ERR_KEYRING_OPEN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_PACKET",SWIG_From_long((long)(GPG_ERR_INV_PACKET)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_ARMOR",SWIG_From_long((long)(GPG_ERR_INV_ARMOR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_USER_ID",SWIG_From_long((long)(GPG_ERR_NO_USER_ID)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_SECKEY",SWIG_From_long((long)(GPG_ERR_NO_SECKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WRONG_SECKEY",SWIG_From_long((long)(GPG_ERR_WRONG_SECKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_KEY",SWIG_From_long((long)(GPG_ERR_BAD_KEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_COMPR_ALGO",SWIG_From_long((long)(GPG_ERR_COMPR_ALGO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_PRIME",SWIG_From_long((long)(GPG_ERR_NO_PRIME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_ENCODING_METHOD",SWIG_From_long((long)(GPG_ERR_NO_ENCODING_METHOD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_ENCRYPTION_SCHEME",SWIG_From_long((long)(GPG_ERR_NO_ENCRYPTION_SCHEME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_SIGNATURE_SCHEME",SWIG_From_long((long)(GPG_ERR_NO_SIGNATURE_SCHEME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_ATTR",SWIG_From_long((long)(GPG_ERR_INV_ATTR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_VALUE",SWIG_From_long((long)(GPG_ERR_NO_VALUE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_FOUND",SWIG_From_long((long)(GPG_ERR_NOT_FOUND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_VALUE_NOT_FOUND",SWIG_From_long((long)(GPG_ERR_VALUE_NOT_FOUND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SYNTAX",SWIG_From_long((long)(GPG_ERR_SYNTAX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_MPI",SWIG_From_long((long)(GPG_ERR_BAD_MPI)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_PASSPHRASE",SWIG_From_long((long)(GPG_ERR_INV_PASSPHRASE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SIG_CLASS",SWIG_From_long((long)(GPG_ERR_SIG_CLASS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_RESOURCE_LIMIT",SWIG_From_long((long)(GPG_ERR_RESOURCE_LIMIT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_KEYRING",SWIG_From_long((long)(GPG_ERR_INV_KEYRING)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TRUSTDB",SWIG_From_long((long)(GPG_ERR_TRUSTDB)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_CERT",SWIG_From_long((long)(GPG_ERR_BAD_CERT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_USER_ID",SWIG_From_long((long)(GPG_ERR_INV_USER_ID)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNEXPECTED",SWIG_From_long((long)(GPG_ERR_UNEXPECTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TIME_CONFLICT",SWIG_From_long((long)(GPG_ERR_TIME_CONFLICT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_KEYSERVER",SWIG_From_long((long)(GPG_ERR_KEYSERVER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WRONG_PUBKEY_ALGO",SWIG_From_long((long)(GPG_ERR_WRONG_PUBKEY_ALGO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TRIBUTE_TO_D_A",SWIG_From_long((long)(GPG_ERR_TRIBUTE_TO_D_A)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WEAK_KEY",SWIG_From_long((long)(GPG_ERR_WEAK_KEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_KEYLEN",SWIG_From_long((long)(GPG_ERR_INV_KEYLEN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_ARG",SWIG_From_long((long)(GPG_ERR_INV_ARG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_URI",SWIG_From_long((long)(GPG_ERR_BAD_URI)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_URI",SWIG_From_long((long)(GPG_ERR_INV_URI)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NETWORK",SWIG_From_long((long)(GPG_ERR_NETWORK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_HOST",SWIG_From_long((long)(GPG_ERR_UNKNOWN_HOST)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SELFTEST_FAILED",SWIG_From_long((long)(GPG_ERR_SELFTEST_FAILED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_ENCRYPTED",SWIG_From_long((long)(GPG_ERR_NOT_ENCRYPTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_PROCESSED",SWIG_From_long((long)(GPG_ERR_NOT_PROCESSED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNUSABLE_PUBKEY",SWIG_From_long((long)(GPG_ERR_UNUSABLE_PUBKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNUSABLE_SECKEY",SWIG_From_long((long)(GPG_ERR_UNUSABLE_SECKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_VALUE",SWIG_From_long((long)(GPG_ERR_INV_VALUE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_CERT_CHAIN",SWIG_From_long((long)(GPG_ERR_BAD_CERT_CHAIN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MISSING_CERT",SWIG_From_long((long)(GPG_ERR_MISSING_CERT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_DATA",SWIG_From_long((long)(GPG_ERR_NO_DATA)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BUG",SWIG_From_long((long)(GPG_ERR_BUG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_SUPPORTED",SWIG_From_long((long)(GPG_ERR_NOT_SUPPORTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_OP",SWIG_From_long((long)(GPG_ERR_INV_OP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TIMEOUT",SWIG_From_long((long)(GPG_ERR_TIMEOUT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INTERNAL",SWIG_From_long((long)(GPG_ERR_INTERNAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EOF_GCRYPT",SWIG_From_long((long)(GPG_ERR_EOF_GCRYPT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_OBJ",SWIG_From_long((long)(GPG_ERR_INV_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TOO_SHORT",SWIG_From_long((long)(GPG_ERR_TOO_SHORT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TOO_LARGE",SWIG_From_long((long)(GPG_ERR_TOO_LARGE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_OBJ",SWIG_From_long((long)(GPG_ERR_NO_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_IMPLEMENTED",SWIG_From_long((long)(GPG_ERR_NOT_IMPLEMENTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CONFLICT",SWIG_From_long((long)(GPG_ERR_CONFLICT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_CIPHER_MODE",SWIG_From_long((long)(GPG_ERR_INV_CIPHER_MODE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_FLAG",SWIG_From_long((long)(GPG_ERR_INV_FLAG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_HANDLE",SWIG_From_long((long)(GPG_ERR_INV_HANDLE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TRUNCATED",SWIG_From_long((long)(GPG_ERR_TRUNCATED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INCOMPLETE_LINE",SWIG_From_long((long)(GPG_ERR_INCOMPLETE_LINE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_RESPONSE",SWIG_From_long((long)(GPG_ERR_INV_RESPONSE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_AGENT",SWIG_From_long((long)(GPG_ERR_NO_AGENT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_AGENT",SWIG_From_long((long)(GPG_ERR_AGENT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_DATA",SWIG_From_long((long)(GPG_ERR_INV_DATA)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASSUAN_SERVER_FAULT",SWIG_From_long((long)(GPG_ERR_ASSUAN_SERVER_FAULT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASSUAN",SWIG_From_long((long)(GPG_ERR_ASSUAN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_SESSION_KEY",SWIG_From_long((long)(GPG_ERR_INV_SESSION_KEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_SEXP",SWIG_From_long((long)(GPG_ERR_INV_SEXP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_ALGORITHM",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_ALGORITHM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_PIN_ENTRY",SWIG_From_long((long)(GPG_ERR_NO_PIN_ENTRY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_PIN_ENTRY",SWIG_From_long((long)(GPG_ERR_PIN_ENTRY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_PIN",SWIG_From_long((long)(GPG_ERR_BAD_PIN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_NAME",SWIG_From_long((long)(GPG_ERR_INV_NAME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_DATA",SWIG_From_long((long)(GPG_ERR_BAD_DATA)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_PARAMETER",SWIG_From_long((long)(GPG_ERR_INV_PARAMETER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WRONG_CARD",SWIG_From_long((long)(GPG_ERR_WRONG_CARD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_DIRMNGR",SWIG_From_long((long)(GPG_ERR_NO_DIRMNGR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DIRMNGR",SWIG_From_long((long)(GPG_ERR_DIRMNGR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CERT_REVOKED",SWIG_From_long((long)(GPG_ERR_CERT_REVOKED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_CRL_KNOWN",SWIG_From_long((long)(GPG_ERR_NO_CRL_KNOWN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CRL_TOO_OLD",SWIG_From_long((long)(GPG_ERR_CRL_TOO_OLD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LINE_TOO_LONG",SWIG_From_long((long)(GPG_ERR_LINE_TOO_LONG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_TRUSTED",SWIG_From_long((long)(GPG_ERR_NOT_TRUSTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CANCELED",SWIG_From_long((long)(GPG_ERR_CANCELED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_CA_CERT",SWIG_From_long((long)(GPG_ERR_BAD_CA_CERT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CERT_EXPIRED",SWIG_From_long((long)(GPG_ERR_CERT_EXPIRED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CERT_TOO_YOUNG",SWIG_From_long((long)(GPG_ERR_CERT_TOO_YOUNG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_CERT",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_CERT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_SEXP",SWIG_From_long((long)(GPG_ERR_UNKNOWN_SEXP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_PROTECTION",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_PROTECTION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CORRUPTED_PROTECTION",SWIG_From_long((long)(GPG_ERR_CORRUPTED_PROTECTION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_AMBIGUOUS_NAME",SWIG_From_long((long)(GPG_ERR_AMBIGUOUS_NAME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CARD",SWIG_From_long((long)(GPG_ERR_CARD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CARD_RESET",SWIG_From_long((long)(GPG_ERR_CARD_RESET)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CARD_REMOVED",SWIG_From_long((long)(GPG_ERR_CARD_REMOVED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_CARD",SWIG_From_long((long)(GPG_ERR_INV_CARD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CARD_NOT_PRESENT",SWIG_From_long((long)(GPG_ERR_CARD_NOT_PRESENT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_PKCS15_APP",SWIG_From_long((long)(GPG_ERR_NO_PKCS15_APP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_CONFIRMED",SWIG_From_long((long)(GPG_ERR_NOT_CONFIRMED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CONFIGURATION",SWIG_From_long((long)(GPG_ERR_CONFIGURATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_POLICY_MATCH",SWIG_From_long((long)(GPG_ERR_NO_POLICY_MATCH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_INDEX",SWIG_From_long((long)(GPG_ERR_INV_INDEX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_ID",SWIG_From_long((long)(GPG_ERR_INV_ID)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_SCDAEMON",SWIG_From_long((long)(GPG_ERR_NO_SCDAEMON)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SCDAEMON",SWIG_From_long((long)(GPG_ERR_SCDAEMON)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_PROTOCOL",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_PROTOCOL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_PIN_METHOD",SWIG_From_long((long)(GPG_ERR_BAD_PIN_METHOD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CARD_NOT_INITIALIZED",SWIG_From_long((long)(GPG_ERR_CARD_NOT_INITIALIZED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_OPERATION",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_OPERATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WRONG_KEY_USAGE",SWIG_From_long((long)(GPG_ERR_WRONG_KEY_USAGE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOTHING_FOUND",SWIG_From_long((long)(GPG_ERR_NOTHING_FOUND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WRONG_BLOB_TYPE",SWIG_From_long((long)(GPG_ERR_WRONG_BLOB_TYPE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MISSING_VALUE",SWIG_From_long((long)(GPG_ERR_MISSING_VALUE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_HARDWARE",SWIG_From_long((long)(GPG_ERR_HARDWARE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_PIN_BLOCKED",SWIG_From_long((long)(GPG_ERR_PIN_BLOCKED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USE_CONDITIONS",SWIG_From_long((long)(GPG_ERR_USE_CONDITIONS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_PIN_NOT_SYNCED",SWIG_From_long((long)(GPG_ERR_PIN_NOT_SYNCED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_CRL",SWIG_From_long((long)(GPG_ERR_INV_CRL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_BER",SWIG_From_long((long)(GPG_ERR_BAD_BER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_BER",SWIG_From_long((long)(GPG_ERR_INV_BER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ELEMENT_NOT_FOUND",SWIG_From_long((long)(GPG_ERR_ELEMENT_NOT_FOUND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_IDENTIFIER_NOT_FOUND",SWIG_From_long((long)(GPG_ERR_IDENTIFIER_NOT_FOUND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_TAG",SWIG_From_long((long)(GPG_ERR_INV_TAG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_LENGTH",SWIG_From_long((long)(GPG_ERR_INV_LENGTH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_KEYINFO",SWIG_From_long((long)(GPG_ERR_INV_KEYINFO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNEXPECTED_TAG",SWIG_From_long((long)(GPG_ERR_UNEXPECTED_TAG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_DER_ENCODED",SWIG_From_long((long)(GPG_ERR_NOT_DER_ENCODED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_CMS_OBJ",SWIG_From_long((long)(GPG_ERR_NO_CMS_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_CMS_OBJ",SWIG_From_long((long)(GPG_ERR_INV_CMS_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_CMS_OBJ",SWIG_From_long((long)(GPG_ERR_UNKNOWN_CMS_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_CMS_OBJ",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_CMS_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_ENCODING",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_ENCODING)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_CMS_VERSION",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_CMS_VERSION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_ALGORITHM",SWIG_From_long((long)(GPG_ERR_UNKNOWN_ALGORITHM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_ENGINE",SWIG_From_long((long)(GPG_ERR_INV_ENGINE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_PUBKEY_NOT_TRUSTED",SWIG_From_long((long)(GPG_ERR_PUBKEY_NOT_TRUSTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DECRYPT_FAILED",SWIG_From_long((long)(GPG_ERR_DECRYPT_FAILED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_KEY_EXPIRED",SWIG_From_long((long)(GPG_ERR_KEY_EXPIRED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SIG_EXPIRED",SWIG_From_long((long)(GPG_ERR_SIG_EXPIRED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENCODING_PROBLEM",SWIG_From_long((long)(GPG_ERR_ENCODING_PROBLEM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_STATE",SWIG_From_long((long)(GPG_ERR_INV_STATE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DUP_VALUE",SWIG_From_long((long)(GPG_ERR_DUP_VALUE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MISSING_ACTION",SWIG_From_long((long)(GPG_ERR_MISSING_ACTION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MODULE_NOT_FOUND",SWIG_From_long((long)(GPG_ERR_MODULE_NOT_FOUND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_OID_STRING",SWIG_From_long((long)(GPG_ERR_INV_OID_STRING)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_TIME",SWIG_From_long((long)(GPG_ERR_INV_TIME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_CRL_OBJ",SWIG_From_long((long)(GPG_ERR_INV_CRL_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNSUPPORTED_CRL_VERSION",SWIG_From_long((long)(GPG_ERR_UNSUPPORTED_CRL_VERSION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_CERT_OBJ",SWIG_From_long((long)(GPG_ERR_INV_CERT_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_NAME",SWIG_From_long((long)(GPG_ERR_UNKNOWN_NAME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LOCALE_PROBLEM",SWIG_From_long((long)(GPG_ERR_LOCALE_PROBLEM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_LOCKED",SWIG_From_long((long)(GPG_ERR_NOT_LOCKED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_PROTOCOL_VIOLATION",SWIG_From_long((long)(GPG_ERR_PROTOCOL_VIOLATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_MAC",SWIG_From_long((long)(GPG_ERR_INV_MAC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_REQUEST",SWIG_From_long((long)(GPG_ERR_INV_REQUEST)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_EXTN",SWIG_From_long((long)(GPG_ERR_UNKNOWN_EXTN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_CRIT_EXTN",SWIG_From_long((long)(GPG_ERR_UNKNOWN_CRIT_EXTN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LOCKED",SWIG_From_long((long)(GPG_ERR_LOCKED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_OPTION",SWIG_From_long((long)(GPG_ERR_UNKNOWN_OPTION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_COMMAND",SWIG_From_long((long)(GPG_ERR_UNKNOWN_COMMAND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_OPERATIONAL",SWIG_From_long((long)(GPG_ERR_NOT_OPERATIONAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_PASSPHRASE",SWIG_From_long((long)(GPG_ERR_NO_PASSPHRASE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_PIN",SWIG_From_long((long)(GPG_ERR_NO_PIN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_ENABLED",SWIG_From_long((long)(GPG_ERR_NOT_ENABLED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_ENGINE",SWIG_From_long((long)(GPG_ERR_NO_ENGINE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MISSING_KEY",SWIG_From_long((long)(GPG_ERR_MISSING_KEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TOO_MANY",SWIG_From_long((long)(GPG_ERR_TOO_MANY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LIMIT_REACHED",SWIG_From_long((long)(GPG_ERR_LIMIT_REACHED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NOT_INITIALIZED",SWIG_From_long((long)(GPG_ERR_NOT_INITIALIZED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MISSING_ISSUER_CERT",SWIG_From_long((long)(GPG_ERR_MISSING_ISSUER_CERT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_KEYSERVER",SWIG_From_long((long)(GPG_ERR_NO_KEYSERVER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_CURVE",SWIG_From_long((long)(GPG_ERR_INV_CURVE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_CURVE",SWIG_From_long((long)(GPG_ERR_UNKNOWN_CURVE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DUP_KEY",SWIG_From_long((long)(GPG_ERR_DUP_KEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_AMBIGUOUS",SWIG_From_long((long)(GPG_ERR_AMBIGUOUS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_CRYPT_CTX",SWIG_From_long((long)(GPG_ERR_NO_CRYPT_CTX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WRONG_CRYPT_CTX",SWIG_From_long((long)(GPG_ERR_WRONG_CRYPT_CTX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_CRYPT_CTX",SWIG_From_long((long)(GPG_ERR_BAD_CRYPT_CTX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CRYPT_CTX_CONFLICT",SWIG_From_long((long)(GPG_ERR_CRYPT_CTX_CONFLICT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BROKEN_PUBKEY",SWIG_From_long((long)(GPG_ERR_BROKEN_PUBKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BROKEN_SECKEY",SWIG_From_long((long)(GPG_ERR_BROKEN_SECKEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MAC_ALGO",SWIG_From_long((long)(GPG_ERR_MAC_ALGO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_FULLY_CANCELED",SWIG_From_long((long)(GPG_ERR_FULLY_CANCELED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNFINISHED",SWIG_From_long((long)(GPG_ERR_UNFINISHED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BUFFER_TOO_SHORT",SWIG_From_long((long)(GPG_ERR_BUFFER_TOO_SHORT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_INV_LEN_SPEC",SWIG_From_long((long)(GPG_ERR_SEXP_INV_LEN_SPEC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_STRING_TOO_LONG",SWIG_From_long((long)(GPG_ERR_SEXP_STRING_TOO_LONG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_UNMATCHED_PAREN",SWIG_From_long((long)(GPG_ERR_SEXP_UNMATCHED_PAREN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_NOT_CANONICAL",SWIG_From_long((long)(GPG_ERR_SEXP_NOT_CANONICAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_BAD_CHARACTER",SWIG_From_long((long)(GPG_ERR_SEXP_BAD_CHARACTER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_BAD_QUOTATION",SWIG_From_long((long)(GPG_ERR_SEXP_BAD_QUOTATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_ZERO_PREFIX",SWIG_From_long((long)(GPG_ERR_SEXP_ZERO_PREFIX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_NESTED_DH",SWIG_From_long((long)(GPG_ERR_SEXP_NESTED_DH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_UNMATCHED_DH",SWIG_From_long((long)(GPG_ERR_SEXP_UNMATCHED_DH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_UNEXPECTED_PUNC",SWIG_From_long((long)(GPG_ERR_SEXP_UNEXPECTED_PUNC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_BAD_HEX_CHAR",SWIG_From_long((long)(GPG_ERR_SEXP_BAD_HEX_CHAR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_ODD_HEX_NUMBERS",SWIG_From_long((long)(GPG_ERR_SEXP_ODD_HEX_NUMBERS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SEXP_BAD_OCT_CHAR",SWIG_From_long((long)(GPG_ERR_SEXP_BAD_OCT_CHAR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SUBKEYS_EXP_OR_REV",SWIG_From_long((long)(GPG_ERR_SUBKEYS_EXP_OR_REV)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DB_CORRUPTED",SWIG_From_long((long)(GPG_ERR_DB_CORRUPTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SERVER_FAILED",SWIG_From_long((long)(GPG_ERR_SERVER_FAILED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_NAME",SWIG_From_long((long)(GPG_ERR_NO_NAME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_KEY",SWIG_From_long((long)(GPG_ERR_NO_KEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LEGACY_KEY",SWIG_From_long((long)(GPG_ERR_LEGACY_KEY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_REQUEST_TOO_SHORT",SWIG_From_long((long)(GPG_ERR_REQUEST_TOO_SHORT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_REQUEST_TOO_LONG",SWIG_From_long((long)(GPG_ERR_REQUEST_TOO_LONG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_OBJ_TERM_STATE",SWIG_From_long((long)(GPG_ERR_OBJ_TERM_STATE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_CERT_CHAIN",SWIG_From_long((long)(GPG_ERR_NO_CERT_CHAIN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CERT_TOO_LARGE",SWIG_From_long((long)(GPG_ERR_CERT_TOO_LARGE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_RECORD",SWIG_From_long((long)(GPG_ERR_INV_RECORD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_MAC",SWIG_From_long((long)(GPG_ERR_BAD_MAC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNEXPECTED_MSG",SWIG_From_long((long)(GPG_ERR_UNEXPECTED_MSG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_COMPR_FAILED",SWIG_From_long((long)(GPG_ERR_COMPR_FAILED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WOULD_WRAP",SWIG_From_long((long)(GPG_ERR_WOULD_WRAP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_FATAL_ALERT",SWIG_From_long((long)(GPG_ERR_FATAL_ALERT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_CIPHER",SWIG_From_long((long)(GPG_ERR_NO_CIPHER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MISSING_CLIENT_CERT",SWIG_From_long((long)(GPG_ERR_MISSING_CLIENT_CERT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CLOSE_NOTIFY",SWIG_From_long((long)(GPG_ERR_CLOSE_NOTIFY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TICKET_EXPIRED",SWIG_From_long((long)(GPG_ERR_TICKET_EXPIRED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_TICKET",SWIG_From_long((long)(GPG_ERR_BAD_TICKET)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_IDENTITY",SWIG_From_long((long)(GPG_ERR_UNKNOWN_IDENTITY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_CERT",SWIG_From_long((long)(GPG_ERR_BAD_HS_CERT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_CERT_REQ",SWIG_From_long((long)(GPG_ERR_BAD_HS_CERT_REQ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_CERT_VER",SWIG_From_long((long)(GPG_ERR_BAD_HS_CERT_VER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_CHANGE_CIPHER",SWIG_From_long((long)(GPG_ERR_BAD_HS_CHANGE_CIPHER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_CLIENT_HELLO",SWIG_From_long((long)(GPG_ERR_BAD_HS_CLIENT_HELLO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_SERVER_HELLO",SWIG_From_long((long)(GPG_ERR_BAD_HS_SERVER_HELLO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_SERVER_HELLO_DONE",SWIG_From_long((long)(GPG_ERR_BAD_HS_SERVER_HELLO_DONE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_FINISHED",SWIG_From_long((long)(GPG_ERR_BAD_HS_FINISHED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_SERVER_KEX",SWIG_From_long((long)(GPG_ERR_BAD_HS_SERVER_KEX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_HS_CLIENT_KEX",SWIG_From_long((long)(GPG_ERR_BAD_HS_CLIENT_KEX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BOGUS_STRING",SWIG_From_long((long)(GPG_ERR_BOGUS_STRING)));
  SWIG_Python_SetConstant(d, "GPG_ERR_FORBIDDEN",SWIG_From_long((long)(GPG_ERR_FORBIDDEN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_KEY_DISABLED",SWIG_From_long((long)(GPG_ERR_KEY_DISABLED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_KEY_ON_CARD",SWIG_From_long((long)(GPG_ERR_KEY_ON_CARD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_LOCK_OBJ",SWIG_From_long((long)(GPG_ERR_INV_LOCK_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TRUE",SWIG_From_long((long)(GPG_ERR_TRUE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_FALSE",SWIG_From_long((long)(GPG_ERR_FALSE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_GENERAL",SWIG_From_long((long)(GPG_ERR_ASS_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_ACCEPT_FAILED",SWIG_From_long((long)(GPG_ERR_ASS_ACCEPT_FAILED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_CONNECT_FAILED",SWIG_From_long((long)(GPG_ERR_ASS_CONNECT_FAILED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_INV_RESPONSE",SWIG_From_long((long)(GPG_ERR_ASS_INV_RESPONSE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_INV_VALUE",SWIG_From_long((long)(GPG_ERR_ASS_INV_VALUE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_INCOMPLETE_LINE",SWIG_From_long((long)(GPG_ERR_ASS_INCOMPLETE_LINE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_LINE_TOO_LONG",SWIG_From_long((long)(GPG_ERR_ASS_LINE_TOO_LONG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_NESTED_COMMANDS",SWIG_From_long((long)(GPG_ERR_ASS_NESTED_COMMANDS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_NO_DATA_CB",SWIG_From_long((long)(GPG_ERR_ASS_NO_DATA_CB)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_NO_INQUIRE_CB",SWIG_From_long((long)(GPG_ERR_ASS_NO_INQUIRE_CB)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_NOT_A_SERVER",SWIG_From_long((long)(GPG_ERR_ASS_NOT_A_SERVER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_NOT_A_CLIENT",SWIG_From_long((long)(GPG_ERR_ASS_NOT_A_CLIENT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_SERVER_START",SWIG_From_long((long)(GPG_ERR_ASS_SERVER_START)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_READ_ERROR",SWIG_From_long((long)(GPG_ERR_ASS_READ_ERROR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_WRITE_ERROR",SWIG_From_long((long)(GPG_ERR_ASS_WRITE_ERROR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_TOO_MUCH_DATA",SWIG_From_long((long)(GPG_ERR_ASS_TOO_MUCH_DATA)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_UNEXPECTED_CMD",SWIG_From_long((long)(GPG_ERR_ASS_UNEXPECTED_CMD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_UNKNOWN_CMD",SWIG_From_long((long)(GPG_ERR_ASS_UNKNOWN_CMD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_SYNTAX",SWIG_From_long((long)(GPG_ERR_ASS_SYNTAX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_CANCELED",SWIG_From_long((long)(GPG_ERR_ASS_CANCELED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_NO_INPUT",SWIG_From_long((long)(GPG_ERR_ASS_NO_INPUT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_NO_OUTPUT",SWIG_From_long((long)(GPG_ERR_ASS_NO_OUTPUT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_PARAMETER",SWIG_From_long((long)(GPG_ERR_ASS_PARAMETER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ASS_UNKNOWN_INQUIRE",SWIG_From_long((long)(GPG_ERR_ASS_UNKNOWN_INQUIRE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENGINE_TOO_OLD",SWIG_From_long((long)(GPG_ERR_ENGINE_TOO_OLD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WINDOW_TOO_SMALL",SWIG_From_long((long)(GPG_ERR_WINDOW_TOO_SMALL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WINDOW_TOO_LARGE",SWIG_From_long((long)(GPG_ERR_WINDOW_TOO_LARGE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MISSING_ENVVAR",SWIG_From_long((long)(GPG_ERR_MISSING_ENVVAR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_ID_EXISTS",SWIG_From_long((long)(GPG_ERR_USER_ID_EXISTS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NAME_EXISTS",SWIG_From_long((long)(GPG_ERR_NAME_EXISTS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DUP_NAME",SWIG_From_long((long)(GPG_ERR_DUP_NAME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TOO_YOUNG",SWIG_From_long((long)(GPG_ERR_TOO_YOUNG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TOO_OLD",SWIG_From_long((long)(GPG_ERR_TOO_OLD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_FLAG",SWIG_From_long((long)(GPG_ERR_UNKNOWN_FLAG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_INV_ORDER",SWIG_From_long((long)(GPG_ERR_INV_ORDER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ALREADY_FETCHED",SWIG_From_long((long)(GPG_ERR_ALREADY_FETCHED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_TRY_LATER",SWIG_From_long((long)(GPG_ERR_TRY_LATER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_WRONG_NAME",SWIG_From_long((long)(GPG_ERR_WRONG_NAME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_NO_AUTH",SWIG_From_long((long)(GPG_ERR_NO_AUTH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_BAD_AUTH",SWIG_From_long((long)(GPG_ERR_BAD_AUTH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_SYSTEM_BUG",SWIG_From_long((long)(GPG_ERR_SYSTEM_BUG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DNS_UNKNOWN",SWIG_From_long((long)(GPG_ERR_DNS_UNKNOWN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DNS_SECTION",SWIG_From_long((long)(GPG_ERR_DNS_SECTION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DNS_ADDRESS",SWIG_From_long((long)(GPG_ERR_DNS_ADDRESS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DNS_NO_QUERY",SWIG_From_long((long)(GPG_ERR_DNS_NO_QUERY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DNS_NO_ANSWER",SWIG_From_long((long)(GPG_ERR_DNS_NO_ANSWER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DNS_CLOSED",SWIG_From_long((long)(GPG_ERR_DNS_CLOSED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DNS_VERIFY",SWIG_From_long((long)(GPG_ERR_DNS_VERIFY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_DNS_TIMEOUT",SWIG_From_long((long)(GPG_ERR_DNS_TIMEOUT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_ATTR_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_ATTR_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NAME_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_NAME_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_SECURITY_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_SECURITY_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_SERVICE_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_SERVICE_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_UPDATE_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_UPDATE_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_E_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_E_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_X_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_X_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_OTHER_GENERAL",SWIG_From_long((long)(GPG_ERR_LDAP_OTHER_GENERAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_X_CONNECTING",SWIG_From_long((long)(GPG_ERR_LDAP_X_CONNECTING)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_REFERRAL_LIMIT",SWIG_From_long((long)(GPG_ERR_LDAP_REFERRAL_LIMIT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CLIENT_LOOP",SWIG_From_long((long)(GPG_ERR_LDAP_CLIENT_LOOP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NO_RESULTS",SWIG_From_long((long)(GPG_ERR_LDAP_NO_RESULTS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CONTROL_NOT_FOUND",SWIG_From_long((long)(GPG_ERR_LDAP_CONTROL_NOT_FOUND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NOT_SUPPORTED",SWIG_From_long((long)(GPG_ERR_LDAP_NOT_SUPPORTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CONNECT",SWIG_From_long((long)(GPG_ERR_LDAP_CONNECT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NO_MEMORY",SWIG_From_long((long)(GPG_ERR_LDAP_NO_MEMORY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_PARAM",SWIG_From_long((long)(GPG_ERR_LDAP_PARAM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_USER_CANCELLED",SWIG_From_long((long)(GPG_ERR_LDAP_USER_CANCELLED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_FILTER",SWIG_From_long((long)(GPG_ERR_LDAP_FILTER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_AUTH_UNKNOWN",SWIG_From_long((long)(GPG_ERR_LDAP_AUTH_UNKNOWN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_TIMEOUT",SWIG_From_long((long)(GPG_ERR_LDAP_TIMEOUT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_DECODING",SWIG_From_long((long)(GPG_ERR_LDAP_DECODING)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_ENCODING",SWIG_From_long((long)(GPG_ERR_LDAP_ENCODING)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_LOCAL",SWIG_From_long((long)(GPG_ERR_LDAP_LOCAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_SERVER_DOWN",SWIG_From_long((long)(GPG_ERR_LDAP_SERVER_DOWN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_SUCCESS",SWIG_From_long((long)(GPG_ERR_LDAP_SUCCESS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_OPERATIONS",SWIG_From_long((long)(GPG_ERR_LDAP_OPERATIONS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_PROTOCOL",SWIG_From_long((long)(GPG_ERR_LDAP_PROTOCOL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_TIMELIMIT",SWIG_From_long((long)(GPG_ERR_LDAP_TIMELIMIT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_SIZELIMIT",SWIG_From_long((long)(GPG_ERR_LDAP_SIZELIMIT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_COMPARE_FALSE",SWIG_From_long((long)(GPG_ERR_LDAP_COMPARE_FALSE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_COMPARE_TRUE",SWIG_From_long((long)(GPG_ERR_LDAP_COMPARE_TRUE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_UNSUPPORTED_AUTH",SWIG_From_long((long)(GPG_ERR_LDAP_UNSUPPORTED_AUTH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_STRONG_AUTH_RQRD",SWIG_From_long((long)(GPG_ERR_LDAP_STRONG_AUTH_RQRD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_PARTIAL_RESULTS",SWIG_From_long((long)(GPG_ERR_LDAP_PARTIAL_RESULTS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_REFERRAL",SWIG_From_long((long)(GPG_ERR_LDAP_REFERRAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_ADMINLIMIT",SWIG_From_long((long)(GPG_ERR_LDAP_ADMINLIMIT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_UNAVAIL_CRIT_EXTN",SWIG_From_long((long)(GPG_ERR_LDAP_UNAVAIL_CRIT_EXTN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CONFIDENT_RQRD",SWIG_From_long((long)(GPG_ERR_LDAP_CONFIDENT_RQRD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_SASL_BIND_INPROG",SWIG_From_long((long)(GPG_ERR_LDAP_SASL_BIND_INPROG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NO_SUCH_ATTRIBUTE",SWIG_From_long((long)(GPG_ERR_LDAP_NO_SUCH_ATTRIBUTE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_UNDEFINED_TYPE",SWIG_From_long((long)(GPG_ERR_LDAP_UNDEFINED_TYPE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_BAD_MATCHING",SWIG_From_long((long)(GPG_ERR_LDAP_BAD_MATCHING)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CONST_VIOLATION",SWIG_From_long((long)(GPG_ERR_LDAP_CONST_VIOLATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_TYPE_VALUE_EXISTS",SWIG_From_long((long)(GPG_ERR_LDAP_TYPE_VALUE_EXISTS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_INV_SYNTAX",SWIG_From_long((long)(GPG_ERR_LDAP_INV_SYNTAX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NO_SUCH_OBJ",SWIG_From_long((long)(GPG_ERR_LDAP_NO_SUCH_OBJ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_ALIAS_PROBLEM",SWIG_From_long((long)(GPG_ERR_LDAP_ALIAS_PROBLEM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_INV_DN_SYNTAX",SWIG_From_long((long)(GPG_ERR_LDAP_INV_DN_SYNTAX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_IS_LEAF",SWIG_From_long((long)(GPG_ERR_LDAP_IS_LEAF)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_ALIAS_DEREF",SWIG_From_long((long)(GPG_ERR_LDAP_ALIAS_DEREF)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_X_PROXY_AUTH_FAIL",SWIG_From_long((long)(GPG_ERR_LDAP_X_PROXY_AUTH_FAIL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_BAD_AUTH",SWIG_From_long((long)(GPG_ERR_LDAP_BAD_AUTH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_INV_CREDENTIALS",SWIG_From_long((long)(GPG_ERR_LDAP_INV_CREDENTIALS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_INSUFFICIENT_ACC",SWIG_From_long((long)(GPG_ERR_LDAP_INSUFFICIENT_ACC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_BUSY",SWIG_From_long((long)(GPG_ERR_LDAP_BUSY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_UNAVAILABLE",SWIG_From_long((long)(GPG_ERR_LDAP_UNAVAILABLE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_UNWILL_TO_PERFORM",SWIG_From_long((long)(GPG_ERR_LDAP_UNWILL_TO_PERFORM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_LOOP_DETECT",SWIG_From_long((long)(GPG_ERR_LDAP_LOOP_DETECT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NAMING_VIOLATION",SWIG_From_long((long)(GPG_ERR_LDAP_NAMING_VIOLATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_OBJ_CLS_VIOLATION",SWIG_From_long((long)(GPG_ERR_LDAP_OBJ_CLS_VIOLATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NOT_ALLOW_NONLEAF",SWIG_From_long((long)(GPG_ERR_LDAP_NOT_ALLOW_NONLEAF)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NOT_ALLOW_ON_RDN",SWIG_From_long((long)(GPG_ERR_LDAP_NOT_ALLOW_ON_RDN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_ALREADY_EXISTS",SWIG_From_long((long)(GPG_ERR_LDAP_ALREADY_EXISTS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NO_OBJ_CLASS_MODS",SWIG_From_long((long)(GPG_ERR_LDAP_NO_OBJ_CLASS_MODS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_RESULTS_TOO_LARGE",SWIG_From_long((long)(GPG_ERR_LDAP_RESULTS_TOO_LARGE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_AFFECTS_MULT_DSAS",SWIG_From_long((long)(GPG_ERR_LDAP_AFFECTS_MULT_DSAS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_VLV",SWIG_From_long((long)(GPG_ERR_LDAP_VLV)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_OTHER",SWIG_From_long((long)(GPG_ERR_LDAP_OTHER)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CUP_RESOURCE_LIMIT",SWIG_From_long((long)(GPG_ERR_LDAP_CUP_RESOURCE_LIMIT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CUP_SEC_VIOLATION",SWIG_From_long((long)(GPG_ERR_LDAP_CUP_SEC_VIOLATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CUP_INV_DATA",SWIG_From_long((long)(GPG_ERR_LDAP_CUP_INV_DATA)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CUP_UNSUP_SCHEME",SWIG_From_long((long)(GPG_ERR_LDAP_CUP_UNSUP_SCHEME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CUP_RELOAD",SWIG_From_long((long)(GPG_ERR_LDAP_CUP_RELOAD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CANCELLED",SWIG_From_long((long)(GPG_ERR_LDAP_CANCELLED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_NO_SUCH_OPERATION",SWIG_From_long((long)(GPG_ERR_LDAP_NO_SUCH_OPERATION)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_TOO_LATE",SWIG_From_long((long)(GPG_ERR_LDAP_TOO_LATE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_CANNOT_CANCEL",SWIG_From_long((long)(GPG_ERR_LDAP_CANNOT_CANCEL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_ASSERTION_FAILED",SWIG_From_long((long)(GPG_ERR_LDAP_ASSERTION_FAILED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_LDAP_PROX_AUTH_DENIED",SWIG_From_long((long)(GPG_ERR_LDAP_PROX_AUTH_DENIED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_1",SWIG_From_long((long)(GPG_ERR_USER_1)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_2",SWIG_From_long((long)(GPG_ERR_USER_2)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_3",SWIG_From_long((long)(GPG_ERR_USER_3)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_4",SWIG_From_long((long)(GPG_ERR_USER_4)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_5",SWIG_From_long((long)(GPG_ERR_USER_5)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_6",SWIG_From_long((long)(GPG_ERR_USER_6)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_7",SWIG_From_long((long)(GPG_ERR_USER_7)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_8",SWIG_From_long((long)(GPG_ERR_USER_8)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_9",SWIG_From_long((long)(GPG_ERR_USER_9)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_10",SWIG_From_long((long)(GPG_ERR_USER_10)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_11",SWIG_From_long((long)(GPG_ERR_USER_11)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_12",SWIG_From_long((long)(GPG_ERR_USER_12)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_13",SWIG_From_long((long)(GPG_ERR_USER_13)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_14",SWIG_From_long((long)(GPG_ERR_USER_14)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_15",SWIG_From_long((long)(GPG_ERR_USER_15)));
  SWIG_Python_SetConstant(d, "GPG_ERR_USER_16",SWIG_From_long((long)(GPG_ERR_USER_16)));
  SWIG_Python_SetConstant(d, "GPG_ERR_MISSING_ERRNO",SWIG_From_long((long)(GPG_ERR_MISSING_ERRNO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_UNKNOWN_ERRNO",SWIG_From_long((long)(GPG_ERR_UNKNOWN_ERRNO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EOF",SWIG_From_long((long)(GPG_ERR_EOF)));
  SWIG_Python_SetConstant(d, "GPG_ERR_E2BIG",SWIG_From_long((long)(GPG_ERR_E2BIG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EACCES",SWIG_From_long((long)(GPG_ERR_EACCES)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EADDRINUSE",SWIG_From_long((long)(GPG_ERR_EADDRINUSE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EADDRNOTAVAIL",SWIG_From_long((long)(GPG_ERR_EADDRNOTAVAIL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EADV",SWIG_From_long((long)(GPG_ERR_EADV)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EAFNOSUPPORT",SWIG_From_long((long)(GPG_ERR_EAFNOSUPPORT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EAGAIN",SWIG_From_long((long)(GPG_ERR_EAGAIN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EALREADY",SWIG_From_long((long)(GPG_ERR_EALREADY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EAUTH",SWIG_From_long((long)(GPG_ERR_EAUTH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBACKGROUND",SWIG_From_long((long)(GPG_ERR_EBACKGROUND)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBADE",SWIG_From_long((long)(GPG_ERR_EBADE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBADF",SWIG_From_long((long)(GPG_ERR_EBADF)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBADFD",SWIG_From_long((long)(GPG_ERR_EBADFD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBADMSG",SWIG_From_long((long)(GPG_ERR_EBADMSG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBADR",SWIG_From_long((long)(GPG_ERR_EBADR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBADRPC",SWIG_From_long((long)(GPG_ERR_EBADRPC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBADRQC",SWIG_From_long((long)(GPG_ERR_EBADRQC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBADSLT",SWIG_From_long((long)(GPG_ERR_EBADSLT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBFONT",SWIG_From_long((long)(GPG_ERR_EBFONT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EBUSY",SWIG_From_long((long)(GPG_ERR_EBUSY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ECANCELED",SWIG_From_long((long)(GPG_ERR_ECANCELED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ECHILD",SWIG_From_long((long)(GPG_ERR_ECHILD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ECHRNG",SWIG_From_long((long)(GPG_ERR_ECHRNG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ECOMM",SWIG_From_long((long)(GPG_ERR_ECOMM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ECONNABORTED",SWIG_From_long((long)(GPG_ERR_ECONNABORTED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ECONNREFUSED",SWIG_From_long((long)(GPG_ERR_ECONNREFUSED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ECONNRESET",SWIG_From_long((long)(GPG_ERR_ECONNRESET)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ED",SWIG_From_long((long)(GPG_ERR_ED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EDEADLK",SWIG_From_long((long)(GPG_ERR_EDEADLK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EDEADLOCK",SWIG_From_long((long)(GPG_ERR_EDEADLOCK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EDESTADDRREQ",SWIG_From_long((long)(GPG_ERR_EDESTADDRREQ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EDIED",SWIG_From_long((long)(GPG_ERR_EDIED)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EDOM",SWIG_From_long((long)(GPG_ERR_EDOM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EDOTDOT",SWIG_From_long((long)(GPG_ERR_EDOTDOT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EDQUOT",SWIG_From_long((long)(GPG_ERR_EDQUOT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EEXIST",SWIG_From_long((long)(GPG_ERR_EEXIST)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EFAULT",SWIG_From_long((long)(GPG_ERR_EFAULT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EFBIG",SWIG_From_long((long)(GPG_ERR_EFBIG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EFTYPE",SWIG_From_long((long)(GPG_ERR_EFTYPE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EGRATUITOUS",SWIG_From_long((long)(GPG_ERR_EGRATUITOUS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EGREGIOUS",SWIG_From_long((long)(GPG_ERR_EGREGIOUS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EHOSTDOWN",SWIG_From_long((long)(GPG_ERR_EHOSTDOWN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EHOSTUNREACH",SWIG_From_long((long)(GPG_ERR_EHOSTUNREACH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EIDRM",SWIG_From_long((long)(GPG_ERR_EIDRM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EIEIO",SWIG_From_long((long)(GPG_ERR_EIEIO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EILSEQ",SWIG_From_long((long)(GPG_ERR_EILSEQ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EINPROGRESS",SWIG_From_long((long)(GPG_ERR_EINPROGRESS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EINTR",SWIG_From_long((long)(GPG_ERR_EINTR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EINVAL",SWIG_From_long((long)(GPG_ERR_EINVAL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EIO",SWIG_From_long((long)(GPG_ERR_EIO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EISCONN",SWIG_From_long((long)(GPG_ERR_EISCONN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EISDIR",SWIG_From_long((long)(GPG_ERR_EISDIR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EISNAM",SWIG_From_long((long)(GPG_ERR_EISNAM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EL2HLT",SWIG_From_long((long)(GPG_ERR_EL2HLT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EL2NSYNC",SWIG_From_long((long)(GPG_ERR_EL2NSYNC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EL3HLT",SWIG_From_long((long)(GPG_ERR_EL3HLT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EL3RST",SWIG_From_long((long)(GPG_ERR_EL3RST)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ELIBACC",SWIG_From_long((long)(GPG_ERR_ELIBACC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ELIBBAD",SWIG_From_long((long)(GPG_ERR_ELIBBAD)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ELIBEXEC",SWIG_From_long((long)(GPG_ERR_ELIBEXEC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ELIBMAX",SWIG_From_long((long)(GPG_ERR_ELIBMAX)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ELIBSCN",SWIG_From_long((long)(GPG_ERR_ELIBSCN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ELNRNG",SWIG_From_long((long)(GPG_ERR_ELNRNG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ELOOP",SWIG_From_long((long)(GPG_ERR_ELOOP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EMEDIUMTYPE",SWIG_From_long((long)(GPG_ERR_EMEDIUMTYPE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EMFILE",SWIG_From_long((long)(GPG_ERR_EMFILE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EMLINK",SWIG_From_long((long)(GPG_ERR_EMLINK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EMSGSIZE",SWIG_From_long((long)(GPG_ERR_EMSGSIZE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EMULTIHOP",SWIG_From_long((long)(GPG_ERR_EMULTIHOP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENAMETOOLONG",SWIG_From_long((long)(GPG_ERR_ENAMETOOLONG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENAVAIL",SWIG_From_long((long)(GPG_ERR_ENAVAIL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENEEDAUTH",SWIG_From_long((long)(GPG_ERR_ENEEDAUTH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENETDOWN",SWIG_From_long((long)(GPG_ERR_ENETDOWN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENETRESET",SWIG_From_long((long)(GPG_ERR_ENETRESET)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENETUNREACH",SWIG_From_long((long)(GPG_ERR_ENETUNREACH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENFILE",SWIG_From_long((long)(GPG_ERR_ENFILE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOANO",SWIG_From_long((long)(GPG_ERR_ENOANO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOBUFS",SWIG_From_long((long)(GPG_ERR_ENOBUFS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOCSI",SWIG_From_long((long)(GPG_ERR_ENOCSI)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENODATA",SWIG_From_long((long)(GPG_ERR_ENODATA)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENODEV",SWIG_From_long((long)(GPG_ERR_ENODEV)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOENT",SWIG_From_long((long)(GPG_ERR_ENOENT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOEXEC",SWIG_From_long((long)(GPG_ERR_ENOEXEC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOLCK",SWIG_From_long((long)(GPG_ERR_ENOLCK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOLINK",SWIG_From_long((long)(GPG_ERR_ENOLINK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOMEDIUM",SWIG_From_long((long)(GPG_ERR_ENOMEDIUM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOMEM",SWIG_From_long((long)(GPG_ERR_ENOMEM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOMSG",SWIG_From_long((long)(GPG_ERR_ENOMSG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENONET",SWIG_From_long((long)(GPG_ERR_ENONET)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOPKG",SWIG_From_long((long)(GPG_ERR_ENOPKG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOPROTOOPT",SWIG_From_long((long)(GPG_ERR_ENOPROTOOPT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOSPC",SWIG_From_long((long)(GPG_ERR_ENOSPC)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOSR",SWIG_From_long((long)(GPG_ERR_ENOSR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOSTR",SWIG_From_long((long)(GPG_ERR_ENOSTR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOSYS",SWIG_From_long((long)(GPG_ERR_ENOSYS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTBLK",SWIG_From_long((long)(GPG_ERR_ENOTBLK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTCONN",SWIG_From_long((long)(GPG_ERR_ENOTCONN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTDIR",SWIG_From_long((long)(GPG_ERR_ENOTDIR)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTEMPTY",SWIG_From_long((long)(GPG_ERR_ENOTEMPTY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTNAM",SWIG_From_long((long)(GPG_ERR_ENOTNAM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTSOCK",SWIG_From_long((long)(GPG_ERR_ENOTSOCK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTSUP",SWIG_From_long((long)(GPG_ERR_ENOTSUP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTTY",SWIG_From_long((long)(GPG_ERR_ENOTTY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENOTUNIQ",SWIG_From_long((long)(GPG_ERR_ENOTUNIQ)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ENXIO",SWIG_From_long((long)(GPG_ERR_ENXIO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EOPNOTSUPP",SWIG_From_long((long)(GPG_ERR_EOPNOTSUPP)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EOVERFLOW",SWIG_From_long((long)(GPG_ERR_EOVERFLOW)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPERM",SWIG_From_long((long)(GPG_ERR_EPERM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPFNOSUPPORT",SWIG_From_long((long)(GPG_ERR_EPFNOSUPPORT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPIPE",SWIG_From_long((long)(GPG_ERR_EPIPE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPROCLIM",SWIG_From_long((long)(GPG_ERR_EPROCLIM)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPROCUNAVAIL",SWIG_From_long((long)(GPG_ERR_EPROCUNAVAIL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPROGMISMATCH",SWIG_From_long((long)(GPG_ERR_EPROGMISMATCH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPROGUNAVAIL",SWIG_From_long((long)(GPG_ERR_EPROGUNAVAIL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPROTO",SWIG_From_long((long)(GPG_ERR_EPROTO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPROTONOSUPPORT",SWIG_From_long((long)(GPG_ERR_EPROTONOSUPPORT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EPROTOTYPE",SWIG_From_long((long)(GPG_ERR_EPROTOTYPE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ERANGE",SWIG_From_long((long)(GPG_ERR_ERANGE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EREMCHG",SWIG_From_long((long)(GPG_ERR_EREMCHG)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EREMOTE",SWIG_From_long((long)(GPG_ERR_EREMOTE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EREMOTEIO",SWIG_From_long((long)(GPG_ERR_EREMOTEIO)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ERESTART",SWIG_From_long((long)(GPG_ERR_ERESTART)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EROFS",SWIG_From_long((long)(GPG_ERR_EROFS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ERPCMISMATCH",SWIG_From_long((long)(GPG_ERR_ERPCMISMATCH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ESHUTDOWN",SWIG_From_long((long)(GPG_ERR_ESHUTDOWN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ESOCKTNOSUPPORT",SWIG_From_long((long)(GPG_ERR_ESOCKTNOSUPPORT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ESPIPE",SWIG_From_long((long)(GPG_ERR_ESPIPE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ESRCH",SWIG_From_long((long)(GPG_ERR_ESRCH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ESRMNT",SWIG_From_long((long)(GPG_ERR_ESRMNT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ESTALE",SWIG_From_long((long)(GPG_ERR_ESTALE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ESTRPIPE",SWIG_From_long((long)(GPG_ERR_ESTRPIPE)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ETIME",SWIG_From_long((long)(GPG_ERR_ETIME)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ETIMEDOUT",SWIG_From_long((long)(GPG_ERR_ETIMEDOUT)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ETOOMANYREFS",SWIG_From_long((long)(GPG_ERR_ETOOMANYREFS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_ETXTBSY",SWIG_From_long((long)(GPG_ERR_ETXTBSY)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EUCLEAN",SWIG_From_long((long)(GPG_ERR_EUCLEAN)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EUNATCH",SWIG_From_long((long)(GPG_ERR_EUNATCH)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EUSERS",SWIG_From_long((long)(GPG_ERR_EUSERS)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EWOULDBLOCK",SWIG_From_long((long)(GPG_ERR_EWOULDBLOCK)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EXDEV",SWIG_From_long((long)(GPG_ERR_EXDEV)));
  SWIG_Python_SetConstant(d, "GPG_ERR_EXFULL",SWIG_From_long((long)(GPG_ERR_EXFULL)));
  SWIG_Python_SetConstant(d, "GPG_ERR_CODE_DIM",SWIG_From_long((long)(GPG_ERR_CODE_DIM)));
  PyDict_SetItemString(md,(char *)"cvar", SWIG_globals());
  SWIG_addvarlink(SWIG_globals(),(char *)"gpg_in_tree_build",Swig_var_gpg_in_tree_build_get, Swig_var_gpg_in_tree_build_set);
  
  /* Initialize threading */
  SWIG_PYTHON_INITIALIZE_THREADS;
#if PY_VERSION_HEX >= 0x03000000
  return m;
#else
  return;
#endif
}

