Compile an expression supplied as a String.
An XPathExecutable
which represents the compiled xpath expression object.
The XPathExecutable may be run as many times as required, in the same or a different
thread. The XPathExecutable
is not affected by any changes made to the XPathCompiler
once it has been compiled.
Using this method the XPath processor is provided with a string of Unicode characters, so no decoding is necessary. Any encoding information present in the version declaration is therefore ignored.
XPathExecutable q = compiler.Compile("distinct-values(//*/node-name()");