Compile a query supplied as a Stream.
An XQueryExecutable
which represents the compiled query object.
The XQueryExecutable may be run as many times as required, in the same or a different
thread. The XQueryExecutable
is not affected by any changes made to the XQueryCompiler
once it has been compiled.
The XQuery processor attempts to deduce the encoding of the query
by looking for a byte-order-mark, or if none is present, by looking
for the encoding declaration in the XQuery version declaration.
For this to work, the stream must have the CanSeek
property.
If no encoding information is present, UTF-8 is assumed.
XQueryExecutable q = compiler.Compile(new FileStream("input.xq", FileMode.Open, FileAccess.Read));
XQueryCompiler Class | Saxon.Api Namespace | XQueryCompiler.Compile Overload List