public abstract class UnparsedTextFunction extends SystemFunction
| Constructor and Description |
|---|
UnparsedTextFunction() |
| Modifier and Type | Method and Description |
|---|---|
static java.net.URI |
getAbsoluteURI(java.lang.String href,
java.lang.String baseURI,
XPathContext context) |
int |
getSpecialProperties(Expression[] arguments)
Determine the special properties of this function.
|
static XPathException |
handleIOError(java.net.URI absoluteURI,
java.io.IOException ioErr,
XPathContext context) |
static java.lang.CharSequence |
readFile(java.util.function.IntPredicate checker,
java.io.Reader reader)
Read the contents of an unparsed text file
|
static void |
readFile(java.util.function.IntPredicate checker,
java.io.Reader reader,
CharSequenceConsumer output)
Read the contents of an unparsed text file
|
static void |
readFile(java.net.URI absoluteURI,
java.lang.String encoding,
CharSequenceConsumer output,
XPathContext context)
Supporting routine to load one external file given a URI (href) and a baseURI
|
dependsOnContextItem, dynamicCall, equals, export, exportAdditionalArguments, exportAttributes, fixArguments, getArity, getCardinality, getCompilerName, getContextNode, getDescription, getDetails, getErrorCodeForTypeErrors, getFunctionItemType, getFunctionName, getIntegerBounds, getNetCost, getOperandRoles, getRequiredType, getResultItemType, getResultItemType, getRetainedStaticContext, getStaticBaseUriString, getStreamerName, importAttributes, isTrustedResultType, makeCall, makeFunction, makeFunctionCall, makeOptimizedFunctionCall, resultIfEmpty, setArity, setDetails, setRetainedStaticContext, supplyTypeInformation, toShortString, toString, typeCheckCalleratomize, deepEquals, effectiveBooleanValue, getAnnotations, getStringValue, getStringValueCS, isArray, isMap, makeNewContext, simplify, typeCheckclone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitargumentArray, call, getGenregetLength, head, isStreamed, itemAt, iterate, reduce, subsequence, toGroundedValueasIterable, concatenate, containsNode, materializemakeRepeatablepublic int getSpecialProperties(Expression[] arguments)
SystemFunctiongetSpecialProperties in class SystemFunctionarguments - the actual arguments supplied in a call to the functionpublic static void readFile(java.net.URI absoluteURI,
java.lang.String encoding,
CharSequenceConsumer output,
XPathContext context)
throws XPathException
absoluteURI - the absolutized URIencoding - the character encodingoutput - the consumer to which the contents of the file will be sentcontext - the XPath dynamic contextXPathException - if the file cannot be readpublic static java.net.URI getAbsoluteURI(java.lang.String href,
java.lang.String baseURI,
XPathContext context)
throws XPathException
XPathExceptionpublic static XPathException handleIOError(java.net.URI absoluteURI, java.io.IOException ioErr, XPathContext context)
public static java.lang.CharSequence readFile(java.util.function.IntPredicate checker,
java.io.Reader reader)
throws java.io.IOException,
XPathException
checker - predicate for checking whether characters are valid XML charactersreader - Reader to be used for reading the fileCharSequencejava.io.IOException - if a failure occurs reading the fileXPathException - if the file contains illegal characterspublic static void readFile(java.util.function.IntPredicate checker,
java.io.Reader reader,
CharSequenceConsumer output)
throws java.io.IOException,
XPathException
checker - predicate for checking whether characters are valid XML charactersreader - Reader to be used for reading the fileoutput - a consumer object that is supplied incrementally with the contents of the filejava.io.IOException - if a failure occurs reading the fileXPathException - if the file contains illegal charactersCopyright (c) 2004-2021 Saxonica Limited. All rights reserved.