Lines Matching refs:pattern
2 * pattern.c: Implemetation of the template match compilation and lookup
34 #include "pattern.h"
102 const xmlChar *pattern; /* the pattern */
182 if (comp->pattern != NULL)
183 xmlFree((xmlChar *)comp->pattern);
457 if (comp->pattern[0] != '/') {
461 query = xmlStrcat(query, comp->pattern);
463 xmlFree((xmlChar *) comp->pattern);
464 comp->pattern = query;
510 * @comp: the precompiled pattern
515 * Test whether the node matches the pattern, do a direct evalutation
560 newlist = xmlXPathEval(comp->pattern, ctxt->xpathCtxt);
617 * @comp: the precompiled pattern
622 pattern
1197 * @comp: the precompiled pattern list
1504 * @novar: flag to prohibit xslt variables from pattern
1812 * @pattern: an XSLT pattern
1819 * Compile the XSLT pattern and generates a list of precompiled form suitable
1822 * [1] Pattern ::= LocationPathPattern | Pattern '|' LocationPathPattern
1824 * Returns the generated pattern list or NULL in case of failure
1828 xsltCompilePatternInternal(const xmlChar *pattern, xmlDocPtr doc,
1835 if (pattern == NULL) {
1837 "xsltCompilePattern : NULL pattern\n");
1847 while (pattern[current] != 0) {
1849 while (IS_BLANK_CH(pattern[current]))
1853 while ((pattern[end] != 0) && ((pattern[end] != '|') || (level != 0))) {
1854 if (pattern[end] == '[')
1856 else if (pattern[end] == ']')
1858 else if (pattern[end] == '\'') {
1860 while ((pattern[end] != 0) && (pattern[end] != '\''))
1862 } else if (pattern[end] == '"') {
1864 while ((pattern[end] != 0) && (pattern[end] != '"'))
1871 "xsltCompilePattern : NULL pattern\n");
1885 ctxt->base = xmlStrndup(&pattern[start], end - start);
1889 element->pattern = ctxt->base;
1902 element->pattern);
1913 element->pattern);
1960 element->pattern, element->priority);
1962 if (pattern[end] == '|')
1968 "xsltCompilePattern : NULL pattern\n");
1986 * @pattern: an XSLT pattern
1992 * Compile the XSLT pattern and generates a list of precompiled form suitable
1995 * [1] Pattern ::= LocationPathPattern | Pattern '|' LocationPathPattern
1997 * Returns the generated pattern list or NULL in case of failure
2001 xsltCompilePattern(const xmlChar *pattern, xmlDocPtr doc,
2004 return (xsltCompilePatternInternal(pattern, doc, node, style, runtime, 0));
2020 * Register the XSLT pattern associated to @cur
2086 "xsltAddTemplate: invalid compiled pattern\n");
2167 "xsltAddTemplate: invalid compiled pattern\n");
2174 "added pattern : '%s' mode '%s' priority %f\n",
2175 pat->pattern, pat->mode, pat->priority);
2178 "added pattern : '%s' priority %f\n",
2179 pat->pattern, pat->priority);