summaryrefslogtreecommitdiffstats
path: root/Include/codecs.h
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2000-03-10 22:32:23 (GMT)
committerGuido van Rossum <guido@python.org>2000-03-10 22:32:23 (GMT)
commit3094484106f79545262eb9c8604158a742cad56a (patch)
treef202b1c69ccf198630781cbd44ee24370a758201 /Include/codecs.h
parentef2255b1dd19e02163a20217fbe3c364a08d3dfa (diff)
downloadcpython-3094484106f79545262eb9c8604158a742cad56a.zip
cpython-3094484106f79545262eb9c8604158a742cad56a.tar.gz
cpython-3094484106f79545262eb9c8604158a742cad56a.tar.bz2
Python Codec Registry and support functions, by Marc-Andre Lemburg.
Diffstat (limited to 'Include/codecs.h')
-rw-r--r--Include/codecs.h55
1 files changed, 55 insertions, 0 deletions
diff --git a/Include/codecs.h b/Include/codecs.h
new file mode 100644
index 0000000..257629d
--- /dev/null
+++ b/Include/codecs.h
@@ -0,0 +1,55 @@
+#ifndef Py_CODECREGISTRY_H
+#define Py_CODECREGISTRY_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/* ------------------------------------------------------------------------
+
+ Python Codec Registry and support functions
+
+
+Written by Marc-Andre Lemburg (mal@lemburg.com).
+
+(c) Copyright CNRI, All Rights Reserved. NO WARRANTY.
+
+ ------------------------------------------------------------------------ */
+
+extern DL_IMPORT(int) PyCodec_Register(
+ PyObject *search_function
+ );
+
+extern DL_IMPORT(PyObject *) _PyCodec_Lookup(
+ const char *encoding
+ );
+
+extern DL_IMPORT(PyObject *) PyCodec_Encoder(
+ const char *encoding
+ );
+
+extern DL_IMPORT(PyObject *) PyCodec_Decoder(
+ const char *encoding
+ );
+
+extern DL_IMPORT(PyObject *) PyCodec_StreamReader(
+ const char *encoding,
+ PyObject *stream,
+ const char *errors
+ );
+
+extern DL_IMPORT(PyObject *) PyCodec_Encode(
+ PyObject *object,
+ const char *encoding,
+ const char *errors
+ );
+
+extern DL_IMPORT(PyObject *) PyCodec_Decode(
+ PyObject *object,
+ const char *encoding,
+ const char *errors
+ );
+
+#ifdef __cplusplus
+}
+#endif
+#endif /* !Py_CODECREGISTRY_H */