|
Packit |
423ecb |
|
|
Packit |
423ecb |
|
|
Packit |
423ecb |
<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><link rel="SHORTCUT ICON" href="/favicon.ico" /><style type="text/css">
|
|
Packit |
423ecb |
TD {font-family: Verdana,Arial,Helvetica}
|
|
Packit |
423ecb |
BODY {font-family: Verdana,Arial,Helvetica; margin-top: 2em; margin-left: 0em; margin-right: 0em}
|
|
Packit |
423ecb |
H1 {font-family: Verdana,Arial,Helvetica}
|
|
Packit |
423ecb |
H2 {font-family: Verdana,Arial,Helvetica}
|
|
Packit |
423ecb |
H3 {font-family: Verdana,Arial,Helvetica}
|
|
Packit |
423ecb |
A:link, A:visited, A:active { text-decoration: underline }
|
|
Packit |
423ecb |
</style><style type="text/css">
|
|
Packit |
423ecb |
div.deprecated pre.programlisting {border-style: double;border-color:red}
|
|
Packit |
423ecb |
pre.programlisting {border-style: double;background: #EECFA1}
|
|
Packit |
423ecb |
</style><title>Module xmlsave from libxml2</title></head><body bgcolor="#8b7765" text="#000000" link="#a06060" vlink="#000000"> | | Module xmlsave from libxml2 |
|
|
<center>API Menu</center> | <form action="../search.php" enctype="application/x-www-form-urlencoded" method="get"><input name="query" type="text" size="20" value="" /><input name="submit" type="submit" value="Search ..." /></form> |
<center>API Indexes</center> | |
<center>Related links</center> | |
|
| API to save document or subtree of document Table of ContentsStructure xmlSaveCtxt struct _xmlSaveCtxt |
|
|
|
|
|
|
Packit |
423ecb |
The content of this structure is not made public by the API.
|
|
Packit |
423ecb |
Typedef xmlSaveCtxt * xmlSaveCtxtPtr
|
|
Packit |
423ecb |
Enum xmlSaveOption
|
|
Packit |
423ecb |
int xmlSaveClose (xmlSaveCtxtPtr ctxt)
|
|
Packit |
423ecb |
long xmlSaveDoc (xmlSaveCtxtPtr ctxt, xmlDocPtr doc)
|
|
Packit |
423ecb |
int xmlSaveFlush (xmlSaveCtxtPtr ctxt)
|
|
Packit |
423ecb |
int xmlSaveSetAttrEscape (xmlSaveCtxtPtr ctxt, xmlCharEncodingOutputFunc escape)
|
|
Packit |
423ecb |
int xmlSaveSetEscape (xmlSaveCtxtPtr ctxt, xmlCharEncodingOutputFunc escape)
|
|
Packit |
423ecb |
xmlSaveCtxtPtr xmlSaveToBuffer (xmlBufferPtr buffer, const char * encoding, int options)
|
|
Packit |
423ecb |
xmlSaveCtxtPtr xmlSaveToFd (int fd, const char * encoding, int options)
|
|
Packit |
423ecb |
xmlSaveCtxtPtr xmlSaveToFilename (const char * filename, const char * encoding, int options)
|
|
Packit |
423ecb |
xmlSaveCtxtPtr xmlSaveToIO (xmlOutputWriteCallback iowrite, xmlOutputCloseCallback ioclose, void * ioctx, const char * encoding, int options)
|
|
Packit |
423ecb |
long xmlSaveTree (xmlSaveCtxtPtr ctxt, xmlNodePtr node)
|
|
Packit |
423ecb |
Description
|
|
Packit |
423ecb |
Structure xmlSaveCtxt struct _xmlSaveCtxt {
|
|
Packit |
423ecb |
The content of this structure is not made public by the API.
|
|
Packit |
423ecb |
}Enum xmlSaveOption {
|
|
Packit |
423ecb |
XML_SAVE_FORMAT = 1 : format save output
|
|
Packit |
423ecb |
XML_SAVE_NO_DECL = 2 : drop the xml declaration
|
|
Packit |
423ecb |
XML_SAVE_NO_EMPTY = 4 : no empty tags
|
|
Packit |
423ecb |
XML_SAVE_NO_XHTML = 8 : disable XHTML1 specific rules
|
|
Packit |
423ecb |
XML_SAVE_XHTML = 16 : force XHTML1 specific rules
|
|
Packit |
423ecb |
XML_SAVE_AS_XML = 32 : force XML serialization on HTML doc
|
|
Packit |
423ecb |
XML_SAVE_AS_HTML = 64 : force HTML serialization on XML doc
|
|
Packit |
423ecb |
XML_SAVE_WSNONSIG = 128 : format with non-significant whitespace
|
|
Packit |
423ecb |
}
|
|
Packit |
423ecb |
Function: xmlSaveCloseint xmlSaveClose (xmlSaveCtxtPtr ctxt)
|
|
Packit |
423ecb |
Close a document saving context, i.e. make sure that all bytes have been output and free the associated data.
|
|
Packit |
423ecb |
<tt>ctxt</tt>: | a document saving context | <tt>Returns</tt>: | the number of byte written or -1 in case of error. |
Function: xmlSaveDoclong xmlSaveDoc (xmlSaveCtxtPtr ctxt, xmlDocPtr doc)
|
|
Packit |
423ecb |
Save a full document to a saving context TODO: The function is not fully implemented yet as it does not return the byte count but 0 instead
|
|
Packit |
423ecb |
<tt>ctxt</tt>: | a document saving context | <tt>doc</tt>: | a document | <tt>Returns</tt>: | the number of byte written or -1 in case of error |
Function: xmlSaveFlushint xmlSaveFlush (xmlSaveCtxtPtr ctxt)
|
|
Packit |
423ecb |
Flush a document saving context, i.e. make sure that all bytes have been output.
|
|
Packit |
423ecb |
<tt>ctxt</tt>: | a document saving context | <tt>Returns</tt>: | the number of byte written or -1 in case of error. |
Function: xmlSaveSetAttrEscapeint xmlSaveSetAttrEscape (xmlSaveCtxtPtr ctxt, xmlCharEncodingOutputFunc escape)
|
|
Packit |
423ecb |
Set a custom escaping function to be used for text in attribute content
|
|
Packit |
423ecb |
<tt>ctxt</tt>: | a document saving context | <tt>escape</tt>: | the escaping function | <tt>Returns</tt>: | 0 if successful or -1 in case of error. |
Function: xmlSaveSetEscapeint xmlSaveSetEscape (xmlSaveCtxtPtr ctxt, xmlCharEncodingOutputFunc escape)
|
|
Packit |
423ecb |
Set a custom escaping function to be used for text in element content
|
|
Packit |
423ecb |
<tt>ctxt</tt>: | a document saving context | <tt>escape</tt>: | the escaping function | <tt>Returns</tt>: | 0 if successful or -1 in case of error. |
Function: xmlSaveToBufferxmlSaveCtxtPtr xmlSaveToBuffer (xmlBufferPtr buffer, const char * encoding, int options)
|
|
Packit |
423ecb |
Create a document saving context serializing to a buffer with the encoding and the options given
|
|
Packit |
423ecb |
<tt>buffer</tt>: | a buffer | <tt>encoding</tt>: | the encoding name to use or NULL | <tt>options</tt>: | a set of xmlSaveOptions | <tt>Returns</tt>: | a new serialization context or NULL in case of error. |
Function: xmlSaveToFdxmlSaveCtxtPtr xmlSaveToFd (int fd, const char * encoding, int options)
|
|
Packit |
423ecb |
Create a document saving context serializing to a file descriptor with the encoding and the options given.
|
|
Packit |
423ecb |
<tt>fd</tt>: | a file descriptor number | <tt>encoding</tt>: | the encoding name to use or NULL | <tt>options</tt>: | a set of xmlSaveOptions | <tt>Returns</tt>: | a new serialization context or NULL in case of error. |
Function: xmlSaveToFilenamexmlSaveCtxtPtr xmlSaveToFilename (const char * filename, const char * encoding, int options)
|
|
Packit |
423ecb |
Create a document saving context serializing to a filename or possibly to an URL (but this is less reliable) with the encoding and the options given.
|
|
Packit |
423ecb |
<tt>filename</tt>: | a file name or an URL | <tt>encoding</tt>: | the encoding name to use or NULL | <tt>options</tt>: | a set of xmlSaveOptions | <tt>Returns</tt>: | a new serialization context or NULL in case of error. |
Function: xmlSaveToIOxmlSaveCtxtPtr xmlSaveToIO (xmlOutputWriteCallback iowrite, xmlOutputCloseCallback ioclose, void * ioctx, const char * encoding, int options)
|
|
Packit |
423ecb |
Create a document saving context serializing to a file descriptor with the encoding and the options given
|
|
Packit |
423ecb |
<tt>iowrite</tt>: | an I/O write function | <tt>ioclose</tt>: | an I/O close function | <tt>ioctx</tt>: | an I/O handler | <tt>encoding</tt>: | the encoding name to use or NULL | <tt>options</tt>: | a set of xmlSaveOptions | <tt>Returns</tt>: | a new serialization context or NULL in case of error. |
Function: xmlSaveTreelong xmlSaveTree (xmlSaveCtxtPtr ctxt, xmlNodePtr node)
|
|
Packit |
423ecb |
Save a subtree starting at the node parameter to a saving context TODO: The function is not fully implemented yet as it does not return the byte count but 0 instead
|
|
Packit |
423ecb |
<tt>ctxt</tt>: | a document saving context | <tt>node</tt>: | the top node of the subtree to save | <tt>Returns</tt>: | the number of byte written or -1 in case of error |
Daniel Veillard </body></html>
|