From 7feb79492a08ef70adb2688b1277fc7c7e49e4d8 Mon Sep 17 00:00:00 2001 From: Valery Febvre Date: Thu, 13 May 2004 23:58:27 +0000 Subject: node_export and node_export_from_base64() functions added --- python/xml/py_xml.c | 30 ++++++++++++++++++++++++++++++ python/xml/py_xml.h | 2 ++ 2 files changed, 32 insertions(+) (limited to 'python/xml') diff --git a/python/xml/py_xml.c b/python/xml/py_xml.c index c1a7a397..d7a44583 100644 --- a/python/xml/py_xml.c +++ b/python/xml/py_xml.c @@ -61,6 +61,36 @@ PyObject *node_dump(PyObject *self, PyObject *args) { return (xmlCharPtr_wrap(ret)); } +PyObject *node_export(PyObject *self, PyObject *args) { + PyObject *node_obj; + xmlChar *ret; + + if (CheckArgs(args, "O:node_export")) { + if(!PyArg_ParseTuple(args, (char *) "O:node_export", &node_obj)) + return NULL; + } + else return NULL; + + ret = lasso_node_export(LassoNode_get(node_obj)); + + return (xmlCharPtr_wrap(ret)); +} + +PyObject *node_export_to_base64(PyObject *self, PyObject *args) { + PyObject *node_obj; + xmlChar *ret; + + if (CheckArgs(args, "O:node_export_to_base64")) { + if(!PyArg_ParseTuple(args, (char *) "O:node_export_to_base64", &node_obj)) + return NULL; + } + else return NULL; + + ret = lasso_node_export_to_base64(LassoNode_get(node_obj)); + + return (xmlCharPtr_wrap(ret)); +} + PyObject *node_export_to_query(PyObject *self, PyObject *args) { PyObject *node_obj; guint sign_method; diff --git a/python/xml/py_xml.h b/python/xml/py_xml.h index 42ff3b82..82d9fed4 100644 --- a/python/xml/py_xml.h +++ b/python/xml/py_xml.h @@ -37,6 +37,8 @@ typedef struct { PyObject *LassoNode_wrap(LassoNode *node); PyObject *node_dump(PyObject *self, PyObject *args); +PyObject *node_export(PyObject *self, PyObject *args); +PyObject *node_export_to_base64(PyObject *self, PyObject *args); PyObject *node_export_to_query(PyObject *self, PyObject *args); PyObject *node_export_to_soap(PyObject *self, PyObject *args); PyObject *node_get_attr_value(PyObject *self, PyObject *args); -- cgit