xmlsave.inc 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. (*
  2. * Summary: the XML document serializer
  3. * Description: API to save document or subtree of document
  4. *
  5. * Copy: See Copyright for the status of this software.
  6. *
  7. * Author: Daniel Veillard
  8. *)
  9. {$IFDEF LIBXML_OUTPUT_ENABLED}
  10. {$IFDEF POINTER}
  11. xmlSaveCtxtPtr = ^xmlSaveCtxt;
  12. {$ENDIF}
  13. (**
  14. * xmlSaveOption:
  15. *
  16. * This is the set of XML save options that can be passed down
  17. * to the xmlSaveToFd() and similar calls.
  18. *)
  19. {$IFDEF TYPE}
  20. xmlSaveCtxt = record end;
  21. xmlSaveOption = type cint;
  22. {$ENDIF}
  23. {$IFDEF CONST}
  24. XML_SAVE_FORMAT = (1 shl 0); (* format save output *)
  25. XML_SAVE_NO_DECL = (1 shl 1); (* drop the xml declaration *)
  26. XML_SAVE_NO_EMPTY = (1 shl 2); (* no empty tags *)
  27. XML_SAVE_NO_XHTML = (1 shl 3); (* disable XHTML1 specific rules *)
  28. XML_SAVE_XHTML = (1 shl 4); (* force XHTML1 specific rules *)
  29. XML_SAVE_AS_XML = (1 shl 5); (* force XML serialization on HTML doc *)
  30. XML_SAVE_AS_HTML = (1 shl 6); (* force HTML serialization on XML doc *)
  31. XML_SAVE_WSNONSIG = (1 shl 7); (* format with non-significant whitespace *)
  32. {$ENDIF}
  33. {$IFDEF FUNCTION}
  34. function xmlSaveToFd(fd: cint; encoding: PAnsiChar; options: cint): xmlSaveCtxtPtr; EXTDECL; external xml2lib;
  35. function xmlSaveToFilename(filename: PAnsiChar; encoding: PAnsiChar; options: cint): xmlSaveCtxtPtr; EXTDECL; external xml2lib;
  36. function xmlSaveToBuffer(buffer: xmlBufferPtr; encoding: PAnsiChar; options: cint): xmlSaveCtxtPtr; EXTDECL; external xml2lib;
  37. function xmlSaveToIO(iowrite: xmlOutputWriteCallback; ioclose: xmlOutputCloseCallback; ioctx: pointer; encoding: PAnsiChar; options: cint): xmlSaveCtxtPtr; EXTDECL; external xml2lib;
  38. function xmlSaveDoc(ctxt: xmlSaveCtxtPtr; doc: xmlDocPtr): clong; EXTDECL; external xml2lib;
  39. function xmlSaveTree(ctxt: xmlSaveCtxtPtr; node: xmlNodePtr): clong; EXTDECL; external xml2lib;
  40. function xmlSaveFlush(ctxt: xmlSaveCtxtPtr): cint; EXTDECL; external xml2lib;
  41. function xmlSaveClose(ctxt: xmlSaveCtxtPtr): cint; EXTDECL; external xml2lib;
  42. function xmlSaveSetEscape(ctxt: xmlSaveCtxtPtr; escape: xmlCharEncodingOutputFunc): cint; EXTDECL; external xml2lib;
  43. function xmlSaveSetAttrEscape(ctxt: xmlSaveCtxtPtr; escape: xmlCharEncodingOutputFunc): cint; EXTDECL; external xml2lib;
  44. {$ENDIF}
  45. {$IFDEF FUNCTIONVAR}
  46. xmlSaveToFd: function(fd: cint; encoding: PAnsiChar; options: cint): xmlSaveCtxtPtr; EXTDECL;
  47. xmlSaveToFilename: function(filename: PAnsiChar; encoding: PAnsiChar; options: cint): xmlSaveCtxtPtr; EXTDECL;
  48. xmlSaveToBuffer: function(buffer: xmlBufferPtr; encoding: PAnsiChar; options: cint): xmlSaveCtxtPtr; EXTDECL;
  49. xmlSaveToIO: function(iowrite: xmlOutputWriteCallback; ioclose: xmlOutputCloseCallback; ioctx: pointer; encoding: PAnsiChar; options: cint): xmlSaveCtxtPtr; EXTDECL;
  50. xmlSaveDoc: function(ctxt: xmlSaveCtxtPtr; doc: xmlDocPtr): clong; EXTDECL;
  51. xmlSaveTree: function(ctxt: xmlSaveCtxtPtr; node: xmlNodePtr): clong; EXTDECL;
  52. xmlSaveFlush: function(ctxt: xmlSaveCtxtPtr): cint; EXTDECL;
  53. xmlSaveClose: function(ctxt: xmlSaveCtxtPtr): cint; EXTDECL;
  54. xmlSaveSetEscape: function(ctxt: xmlSaveCtxtPtr; escape: xmlCharEncodingOutputFunc): cint; EXTDECL;
  55. xmlSaveSetAttrEscape: function(ctxt: xmlSaveCtxtPtr; escape: xmlCharEncodingOutputFunc): cint; EXTDECL;
  56. {$ENDIF}
  57. {$ENDIF} (* LIBXML_OUTPUT_ENABLED *)