summaryrefslogtreecommitdiff
path: root/src/lxml/includes
diff options
context:
space:
mode:
authorStefan Behnel <stefan_ml@behnel.de>2012-11-20 19:32:08 +0100
committerStefan Behnel <stefan_ml@behnel.de>2012-11-20 19:32:08 +0100
commit7e68796d184f838356de80917ec306682f6232f5 (patch)
tree8f1d17fb36a47f273ea20eab2ca92bdca813a167 /src/lxml/includes
parentde23e3ca4cf57b2f728b6442f3575f69ffd77e09 (diff)
downloadpython-lxml-7e68796d184f838356de80917ec306682f6232f5.tar.gz
add new API for incremental XML file generation
Diffstat (limited to 'src/lxml/includes')
-rw-r--r--src/lxml/includes/tree.pxd9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/lxml/includes/tree.pxd b/src/lxml/includes/tree.pxd
index afd49bad..d2a623e2 100644
--- a/src/lxml/includes/tree.pxd
+++ b/src/lxml/includes/tree.pxd
@@ -1,5 +1,5 @@
from libc cimport stdio
-from libc.string cimport const_char
+from libc.string cimport const_char, const_uchar
cdef extern from "lxml-version.h":
# deprecated declaration, use etreepublic.pxd instead
@@ -55,6 +55,8 @@ cdef extern from "libxml/encoding.h":
cdef xmlCharEncoding xmlDetectCharEncoding(const_xmlChar* text, int len) nogil
cdef const_char* xmlGetCharEncodingName(xmlCharEncoding enc) nogil
cdef xmlCharEncoding xmlParseCharEncoding(char* name) nogil
+ ctypedef int (*xmlCharEncodingOutputFunc)(
+ unsigned char *out_buf, int *outlen, const_uchar *in_buf, int *inlen)
cdef extern from "libxml/chvalid.h":
cdef int xmlIsChar_ch(char c) nogil
@@ -383,9 +385,12 @@ cdef extern from "libxml/valid.h":
xmlNotationTable* table) nogil
cdef extern from "libxml/xmlIO.h":
- cdef int xmlOutputBufferWriteString(xmlOutputBuffer* out, const_char* str) nogil
cdef int xmlOutputBufferWrite(xmlOutputBuffer* out,
int len, const_char* str) nogil
+ cdef int xmlOutputBufferWriteString(xmlOutputBuffer* out, const_char* str) nogil
+ cdef int xmlOutputBufferWriteEscape(xmlOutputBuffer* out,
+ const_char* str,
+ xmlCharEncodingOutputFunc escapefunc) nogil
cdef int xmlOutputBufferFlush(xmlOutputBuffer* out) nogil
cdef int xmlOutputBufferClose(xmlOutputBuffer* out) nogil