Home | History | Annotate | Download | only in libxslt
      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 
     12 #ifndef __XML_XSLT_PATTERN_H__
     13 #define __XML_XSLT_PATTERN_H__
     14 
     15 #include "xsltInternals.h"
     16 #include "xsltexports.h"
     17 
     18 #ifdef __cplusplus
     19 extern "C" {
     20 #endif
     21 
     22 /**
     23  * xsltCompMatch:
     24  *
     25  * Data structure used for the implementation of patterns.
     26  * It is kept private (in pattern.c).
     27  */
     28 typedef struct _xsltCompMatch xsltCompMatch;
     29 typedef xsltCompMatch *xsltCompMatchPtr;
     30 
     31 /*
     32  * Pattern related interfaces.
     33  */
     34 
     35 XSLTPUBFUN xsltCompMatchPtr XSLTCALL
     36 		xsltCompilePattern	(const xmlChar *pattern,
     37 					 xmlDocPtr doc,
     38 					 xmlNodePtr node,
     39 					 xsltStylesheetPtr style,
     40 					 xsltTransformContextPtr runtime);
     41 XSLTPUBFUN void XSLTCALL
     42 		xsltFreeCompMatchList	(xsltCompMatchPtr comp);
     43 XSLTPUBFUN int XSLTCALL
     44 		xsltTestCompMatchList	(xsltTransformContextPtr ctxt,
     45 					 xmlNodePtr node,
     46 					 xsltCompMatchPtr comp);
     47 XSLTPUBFUN void XSLTCALL
     48 		xsltNormalizeCompSteps	(void *payload,
     49 					 void *data,
     50 					 const xmlChar *name);
     51 
     52 /*
     53  * Template related interfaces.
     54  */
     55 XSLTPUBFUN int XSLTCALL
     56 		xsltAddTemplate		(xsltStylesheetPtr style,
     57 					 xsltTemplatePtr cur,
     58 					 const xmlChar *mode,
     59 					 const xmlChar *modeURI);
     60 XSLTPUBFUN xsltTemplatePtr XSLTCALL
     61 		xsltGetTemplate		(xsltTransformContextPtr ctxt,
     62 					 xmlNodePtr node,
     63 					 xsltStylesheetPtr style);
     64 XSLTPUBFUN void XSLTCALL
     65 		xsltFreeTemplateHashes	(xsltStylesheetPtr style);
     66 XSLTPUBFUN void XSLTCALL
     67 		xsltCleanupTemplates	(xsltStylesheetPtr style);
     68 
     69 #if 0
     70 int		xsltMatchPattern	(xsltTransformContextPtr ctxt,
     71 					 xmlNodePtr node,
     72 					 const xmlChar *pattern,
     73 					 xmlDocPtr ctxtdoc,
     74 					 xmlNodePtr ctxtnode);
     75 #endif
     76 #ifdef __cplusplus
     77 }
     78 #endif
     79 
     80 #endif /* __XML_XSLT_PATTERN_H__ */
     81 
     82