00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef __XML_XMLSAVE_H__
00011 #define __XML_XMLSAVE_H__
00012
00013 #include <libxml/xmlversion.h>
00014 #include <libxml/tree.h>
00015 #include <libxml/encoding.h>
00016 #include <libxml/xmlIO.h>
00017
00018 #ifdef LIBXML_OUTPUT_ENABLED
00019 #ifdef __cplusplus
00020 extern "C" {
00021 #endif
00022
00029 typedef enum {
00030 XML_SAVE_FORMAT = 1<<0,
00031 XML_SAVE_NO_DECL = 1<<1,
00032 XML_SAVE_NO_EMPTY = 1<<2,
00033 XML_SAVE_NO_XHTML = 1<<3
00034 } xmlSaveOption;
00035
00036
00037 typedef struct _xmlSaveCtxt xmlSaveCtxt;
00038 typedef xmlSaveCtxt *xmlSaveCtxtPtr;
00039
00040 XMLPUBFUN xmlSaveCtxtPtr XMLCALL
00041 xmlSaveToFd (int fd,
00042 const char *encoding,
00043 int options);
00044 XMLPUBFUN xmlSaveCtxtPtr XMLCALL
00045 xmlSaveToFilename (const char *filename,
00046 const char *encoding,
00047 int options);
00048
00049 XMLPUBFUN xmlSaveCtxtPtr XMLCALL
00050 xmlSaveToBuffer (xmlBufferPtr buffer,
00051 const char *encoding,
00052 int options);
00053
00054 XMLPUBFUN xmlSaveCtxtPtr XMLCALL
00055 xmlSaveToIO (xmlOutputWriteCallback iowrite,
00056 xmlOutputCloseCallback ioclose,
00057 void *ioctx,
00058 const char *encoding,
00059 int options);
00060
00061 XMLPUBFUN long XMLCALL
00062 xmlSaveDoc (xmlSaveCtxtPtr ctxt,
00063 xmlDocPtr doc);
00064 XMLPUBFUN long XMLCALL
00065 xmlSaveTree (xmlSaveCtxtPtr ctxt,
00066 xmlNodePtr node);
00067
00068 XMLPUBFUN int XMLCALL
00069 xmlSaveFlush (xmlSaveCtxtPtr ctxt);
00070 XMLPUBFUN int XMLCALL
00071 xmlSaveClose (xmlSaveCtxtPtr ctxt);
00072 XMLPUBFUN int XMLCALL
00073 xmlSaveSetEscape (xmlSaveCtxtPtr ctxt,
00074 xmlCharEncodingOutputFunc escape);
00075 XMLPUBFUN int XMLCALL
00076 xmlSaveSetAttrEscape (xmlSaveCtxtPtr ctxt,
00077 xmlCharEncodingOutputFunc escape);
00078 #ifdef __cplusplus
00079 }
00080 #endif
00081 #endif
00082 #endif
00083
00084