public class XQueryProcessor extends Object implements Serializable
| Modifier and Type | Method and Description |
|---|---|
String |
evaluate(InputStream content)
Evaluate the content with the XQuery expression specified when creating the XQueryProcessor
and return a serialized response.
|
String |
evaluate(String content)
Evaluate the content with the XQuery expression specified when creating the XQueryProcessor
and return a serialized response.
|
String |
evaluateStream(InputStream content)
Evaluate the content with the XQuery expression specified when creating the XQueryProcessor
and return a serialized response.
|
String |
evaluateString(String content)
Evaluate the content with the XQuery expression specified when creating the XQueryProcessor
and return a serialized response.
|
static XQueryProcessor |
getInstance(String xQueryExpression)
Get an instance of XQueryProcessor.
|
static XQueryProcessor |
getInstance(String xQueryExpression,
HashMap<String,String> namespaceMappings)
Get an instance of XQueryProcessor.
|
static XQueryProcessor |
getInstance(String xQueryExpression,
HashMap<String,String> namespaceMappings,
HashMap<String,Object> featureMappings)
Get an instance of XQueryProcessor.
|
void |
setExternalVariable(String name,
String value)
Set the external variable.
|
void |
setOutputMethod(String method)
Set the output method (the default is xml).
|
public static XQueryProcessor getInstance(String xQueryExpression) throws XQueryException
xQueryExpression - XQuery expression to apply to the contentXQueryExceptionpublic static XQueryProcessor getInstance(String xQueryExpression, HashMap<String,String> namespaceMappings) throws XQueryException
xQueryExpression - XQuery expression to apply to the contentnamespaceMappings - Namespace prefix to Namespace uri mappingsXQueryExceptionpublic static XQueryProcessor getInstance(String xQueryExpression, HashMap<String,String> namespaceMappings, HashMap<String,Object> featureMappings) throws XQueryException
xQueryExpression - XQuery expression to apply to the contentnamespaceMappings - Namespace prefix to Namespace uri mappingsfeatureMappings - Processor feature mappingsXQueryExceptionpublic void setOutputMethod(String method)
method - public void setExternalVariable(String name, String value)
name - Name of the external variable in the XQueryvalue - Value for the external variablepublic String evaluate(String content) throws XQueryException
content - String to which the XQuery Expression will be evaluatedXQueryExceptionpublic String evaluateString(String content) throws XQueryException
content - String to which the XQuery Expression will be evaluatedXQueryExceptionpublic String evaluate(InputStream content) throws XQueryException
content - InputStream to which the XQuery Expression will be evaluatedXQueryExceptionpublic String evaluateStream(InputStream content) throws XQueryException
content - InputStream to which the XQuery Expression will be evaluatedXQueryExceptionCopyright © 2018 Elsevier, Inc.. All rights reserved.