You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

81 lines
2.0 KiB

4 years ago
  1. /*
  2. * Summary: interface for the pattern matching used in template matches.
  3. * Description: the implementation of the lookup of the right template
  4. * for a given node must be really fast in order to keep
  5. * decent performances.
  6. *
  7. * Copy: See Copyright for the status of this software.
  8. *
  9. * Author: Daniel Veillard
  10. */
  11. #ifndef __XML_XSLT_PATTERN_H__
  12. #define __XML_XSLT_PATTERN_H__
  13. #include "xsltInternals.h"
  14. #include "xsltexports.h"
  15. #ifdef __cplusplus
  16. extern "C" {
  17. #endif
  18. /**
  19. * xsltCompMatch:
  20. *
  21. * Data structure used for the implementation of patterns.
  22. * It is kept private (in pattern.c).
  23. */
  24. typedef struct _xsltCompMatch xsltCompMatch;
  25. typedef xsltCompMatch *xsltCompMatchPtr;
  26. /*
  27. * Pattern related interfaces.
  28. */
  29. XSLTPUBFUN xsltCompMatchPtr XSLTCALL
  30. xsltCompilePattern (const xmlChar *pattern,
  31. xmlDocPtr doc,
  32. xmlNodePtr node,
  33. xsltStylesheetPtr style,
  34. xsltTransformContextPtr runtime);
  35. XSLTPUBFUN void XSLTCALL
  36. xsltFreeCompMatchList (xsltCompMatchPtr comp);
  37. XSLTPUBFUN int XSLTCALL
  38. xsltTestCompMatchList (xsltTransformContextPtr ctxt,
  39. xmlNodePtr node,
  40. xsltCompMatchPtr comp);
  41. XSLTPUBFUN void XSLTCALL
  42. xsltNormalizeCompSteps (void *payload,
  43. void *data,
  44. const xmlChar *name);
  45. /*
  46. * Template related interfaces.
  47. */
  48. XSLTPUBFUN int XSLTCALL
  49. xsltAddTemplate (xsltStylesheetPtr style,
  50. xsltTemplatePtr cur,
  51. const xmlChar *mode,
  52. const xmlChar *modeURI);
  53. XSLTPUBFUN xsltTemplatePtr XSLTCALL
  54. xsltGetTemplate (xsltTransformContextPtr ctxt,
  55. xmlNodePtr node,
  56. xsltStylesheetPtr style);
  57. XSLTPUBFUN void XSLTCALL
  58. xsltFreeTemplateHashes (xsltStylesheetPtr style);
  59. XSLTPUBFUN void XSLTCALL
  60. xsltCleanupTemplates (xsltStylesheetPtr style);
  61. #if 0
  62. int xsltMatchPattern (xsltTransformContextPtr ctxt,
  63. xmlNodePtr node,
  64. const xmlChar *pattern,
  65. xmlDocPtr ctxtdoc,
  66. xmlNodePtr ctxtnode);
  67. #endif
  68. #ifdef __cplusplus
  69. }
  70. #endif
  71. #endif /* __XML_XSLT_PATTERN_H__ */