xinclude.h 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. /*
  2. * Summary: implementation of XInclude
  3. * Description: API to handle XInclude processing,
  4. * implements the
  5. * World Wide Web Consortium Last Call Working Draft 10 November 2003
  6. * http://www.w3.org/TR/2003/WD-xinclude-20031110
  7. *
  8. * Copy: See Copyright for the status of this software.
  9. *
  10. * Author: Daniel Veillard
  11. */
  12. #ifndef __XML_XINCLUDE_H__
  13. #define __XML_XINCLUDE_H__
  14. #include <libxml/xmlversion.h>
  15. #include <libxml/tree.h>
  16. #ifdef LIBXML_XINCLUDE_ENABLED
  17. #ifdef __cplusplus
  18. extern "C" {
  19. #endif
  20. /**
  21. * XINCLUDE_NS:
  22. *
  23. * Macro defining the Xinclude namespace: http://www.w3.org/2003/XInclude
  24. */
  25. #define XINCLUDE_NS (const xmlChar *) "http://www.w3.org/2003/XInclude"
  26. /**
  27. * XINCLUDE_OLD_NS:
  28. *
  29. * Macro defining the draft Xinclude namespace: http://www.w3.org/2001/XInclude
  30. */
  31. #define XINCLUDE_OLD_NS (const xmlChar *) "http://www.w3.org/2001/XInclude"
  32. /**
  33. * XINCLUDE_NODE:
  34. *
  35. * Macro defining "include"
  36. */
  37. #define XINCLUDE_NODE (const xmlChar *) "include"
  38. /**
  39. * XINCLUDE_FALLBACK:
  40. *
  41. * Macro defining "fallback"
  42. */
  43. #define XINCLUDE_FALLBACK (const xmlChar *) "fallback"
  44. /**
  45. * XINCLUDE_HREF:
  46. *
  47. * Macro defining "href"
  48. */
  49. #define XINCLUDE_HREF (const xmlChar *) "href"
  50. /**
  51. * XINCLUDE_PARSE:
  52. *
  53. * Macro defining "parse"
  54. */
  55. #define XINCLUDE_PARSE (const xmlChar *) "parse"
  56. /**
  57. * XINCLUDE_PARSE_XML:
  58. *
  59. * Macro defining "xml"
  60. */
  61. #define XINCLUDE_PARSE_XML (const xmlChar *) "xml"
  62. /**
  63. * XINCLUDE_PARSE_TEXT:
  64. *
  65. * Macro defining "text"
  66. */
  67. #define XINCLUDE_PARSE_TEXT (const xmlChar *) "text"
  68. /**
  69. * XINCLUDE_PARSE_ENCODING:
  70. *
  71. * Macro defining "encoding"
  72. */
  73. #define XINCLUDE_PARSE_ENCODING (const xmlChar *) "encoding"
  74. /**
  75. * XINCLUDE_PARSE_XPOINTER:
  76. *
  77. * Macro defining "xpointer"
  78. */
  79. #define XINCLUDE_PARSE_XPOINTER (const xmlChar *) "xpointer"
  80. typedef struct _xmlXIncludeCtxt xmlXIncludeCtxt;
  81. typedef xmlXIncludeCtxt *xmlXIncludeCtxtPtr;
  82. /*
  83. * standalone processing
  84. */
  85. XMLPUBFUN int XMLCALL
  86. xmlXIncludeProcess (xmlDocPtr doc);
  87. XMLPUBFUN int XMLCALL
  88. xmlXIncludeProcessFlags (xmlDocPtr doc,
  89. int flags);
  90. XMLPUBFUN int XMLCALL
  91. xmlXIncludeProcessFlagsData(xmlDocPtr doc,
  92. int flags,
  93. void *data);
  94. XMLPUBFUN int XMLCALL
  95. xmlXIncludeProcessTreeFlagsData(xmlNodePtr tree,
  96. int flags,
  97. void *data);
  98. XMLPUBFUN int XMLCALL
  99. xmlXIncludeProcessTree (xmlNodePtr tree);
  100. XMLPUBFUN int XMLCALL
  101. xmlXIncludeProcessTreeFlags(xmlNodePtr tree,
  102. int flags);
  103. /*
  104. * contextual processing
  105. */
  106. XMLPUBFUN xmlXIncludeCtxtPtr XMLCALL
  107. xmlXIncludeNewContext (xmlDocPtr doc);
  108. XMLPUBFUN int XMLCALL
  109. xmlXIncludeSetFlags (xmlXIncludeCtxtPtr ctxt,
  110. int flags);
  111. XMLPUBFUN void XMLCALL
  112. xmlXIncludeFreeContext (xmlXIncludeCtxtPtr ctxt);
  113. XMLPUBFUN int XMLCALL
  114. xmlXIncludeProcessNode (xmlXIncludeCtxtPtr ctxt,
  115. xmlNodePtr tree);
  116. #ifdef __cplusplus
  117. }
  118. #endif
  119. #endif /* LIBXML_XINCLUDE_ENABLED */
  120. #endif /* __XML_XINCLUDE_H__ */