Skip to main content

xsltCompilePattern

Function xsltCompilePattern 

Source
pub unsafe fn xsltCompilePattern(
    pattern: *const xmlChar,
    _doc: *mut _xmlDoc,
) -> *mut _xsltPattern
Expand description

Compile an XSLT pattern string into a compiled pattern.

Parses the pattern string using the XPath 1.0 parser, then decomposes it into an internal representation suitable for fast node matching.

§Parameters

  • pattern — The pattern string (UTF-8, null-terminated xmlChar*).
  • doc — The document (used for namespace resolution; may be null).

§Returns

A pointer to a compiled _xsltPattern, or null on failure.

§Safety

pattern must be a valid null-terminated xmlChar* or null. doc must be a valid _xmlDoc* or null.