buf.h 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. #ifndef XML_BUF_H_PRIVATE__
  2. #define XML_BUF_H_PRIVATE__
  3. #include <libxml/tree.h>
  4. XML_HIDDEN xmlBufPtr
  5. xmlBufCreate(void);
  6. XML_HIDDEN xmlBufPtr
  7. xmlBufCreateSize(size_t size);
  8. XML_HIDDEN int
  9. xmlBufSetAllocationScheme(xmlBufPtr buf, xmlBufferAllocationScheme scheme);
  10. XML_HIDDEN int
  11. xmlBufGetAllocationScheme(xmlBufPtr buf);
  12. XML_HIDDEN void
  13. xmlBufFree(xmlBufPtr buf);
  14. XML_HIDDEN void
  15. xmlBufEmpty(xmlBufPtr buf);
  16. /* size_t xmlBufShrink(xmlBufPtr buf, size_t len); */
  17. XML_HIDDEN int
  18. xmlBufGrow(xmlBufPtr buf, int len);
  19. XML_HIDDEN int
  20. xmlBufResize(xmlBufPtr buf, size_t len);
  21. XML_HIDDEN int
  22. xmlBufAdd(xmlBufPtr buf, const xmlChar *str, int len);
  23. XML_HIDDEN int
  24. xmlBufCat(xmlBufPtr buf, const xmlChar *str);
  25. XML_HIDDEN int
  26. xmlBufCCat(xmlBufPtr buf, const char *str);
  27. XML_HIDDEN int
  28. xmlBufWriteQuotedString(xmlBufPtr buf, const xmlChar *string);
  29. XML_HIDDEN size_t
  30. xmlBufAvail(const xmlBufPtr buf);
  31. XML_HIDDEN size_t
  32. xmlBufLength(const xmlBufPtr buf);
  33. /* size_t xmlBufUse(const xmlBufPtr buf); */
  34. XML_HIDDEN int
  35. xmlBufIsEmpty(const xmlBufPtr buf);
  36. XML_HIDDEN int
  37. xmlBufAddLen(xmlBufPtr buf, size_t len);
  38. /* const xmlChar * xmlBufContent(const xmlBuf *buf); */
  39. /* const xmlChar * xmlBufEnd(xmlBufPtr buf); */
  40. XML_HIDDEN xmlChar *
  41. xmlBufDetach(xmlBufPtr buf);
  42. XML_HIDDEN size_t
  43. xmlBufDump(FILE *file, xmlBufPtr buf);
  44. XML_HIDDEN xmlBufPtr
  45. xmlBufFromBuffer(xmlBufferPtr buffer);
  46. XML_HIDDEN xmlBufferPtr
  47. xmlBufBackToBuffer(xmlBufPtr buf);
  48. XML_HIDDEN int
  49. xmlBufMergeBuffer(xmlBufPtr buf, xmlBufferPtr buffer);
  50. XML_HIDDEN int
  51. xmlBufResetInput(xmlBufPtr buf, xmlParserInputPtr input);
  52. XML_HIDDEN int
  53. xmlBufUpdateInput(xmlBufPtr buf, xmlParserInputPtr input, size_t pos);
  54. #endif /* XML_BUF_H_PRIVATE__ */