version 1.1.1.1, 2012/02/21 23:38:00
|
version 1.1.1.2, 2014/06/15 19:53:33
|
Line 23
|
Line 23
|
#include <libxml/xmlschemas.h> |
#include <libxml/xmlschemas.h> |
#endif |
#endif |
|
|
|
/* |
|
* for older versions of Python, we don't use PyBytes, but keep PyString |
|
* and don't use Capsule but CObjects |
|
*/ |
|
#if PY_VERSION_HEX < 0x02070000 |
|
#ifndef PyBytes_Check |
|
#define PyBytes_Check PyString_Check |
|
#define PyBytes_Size PyString_Size |
|
#define PyBytes_AsString PyString_AsString |
|
#define PyBytes_AS_STRING PyString_AS_STRING |
|
#define PyBytes_GET_SIZE PyString_GET_SIZE |
|
|
|
#define PyCapsule_New PyCObject_FromVoidPtrAndDesc |
|
#define PyCapsule_CheckExact PyCObject_Check |
|
#define PyCapsule_GetPointer(o, n) PyCObject_GetDesc((o)) |
|
|
|
#endif |
|
#endif |
|
|
/** |
/** |
* ATTRIBUTE_UNUSED: |
* ATTRIBUTE_UNUSED: |
* |
* |
Line 150 typedef struct {
|
Line 169 typedef struct {
|
} PyURI_Object; |
} PyURI_Object; |
|
|
/* FILE * have their own internal representation */ |
/* FILE * have their own internal representation */ |
|
#if PY_MAJOR_VERSION >= 3 |
|
FILE *libxml_PyFileGet(PyObject *f); |
|
void libxml_PyFileRelease(FILE *f); |
|
#define PyFile_Get(v) (((v) == Py_None) ? NULL : libxml_PyFileGet(v)) |
|
#define PyFile_Release(f) libxml_PyFileRelease(f) |
|
#else |
#define PyFile_Get(v) (((v) == Py_None) ? NULL : \ |
#define PyFile_Get(v) (((v) == Py_None) ? NULL : \ |
(PyFile_Check(v) ? (PyFile_AsFile(v)) : stdout)) |
(PyFile_Check(v) ? (PyFile_AsFile(v)) : stdout)) |
|
#define PyFile_Release(f) |
|
#endif |
|
|
#ifdef LIBXML_SCHEMAS_ENABLED |
#ifdef LIBXML_SCHEMAS_ENABLED |
typedef struct { |
typedef struct { |
Line 247 PyObject * libxml_xmlSchemaValidCtxtPtrWrap(xmlSchemaV
|
Line 274 PyObject * libxml_xmlSchemaValidCtxtPtrWrap(xmlSchemaV
|
#endif /* LIBXML_SCHEMAS_ENABLED */ |
#endif /* LIBXML_SCHEMAS_ENABLED */ |
PyObject * libxml_xmlErrorPtrWrap(xmlErrorPtr error); |
PyObject * libxml_xmlErrorPtrWrap(xmlErrorPtr error); |
PyObject * libxml_xmlSchemaSetValidErrors(PyObject * self, PyObject * args); |
PyObject * libxml_xmlSchemaSetValidErrors(PyObject * self, PyObject * args); |
|
PyObject * libxml_xmlRegisterInputCallback(PyObject *self, PyObject *args); |
|
PyObject * libxml_xmlUnregisterInputCallback(PyObject *self, PyObject *args); |
|
PyObject * libxml_xmlNodeRemoveNsDef(PyObject * self, PyObject * args); |