|
Oracle® Database XML Java API Reference 12c Release 1 (12.1) E15981-09 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface OXQDynamicContext
Extensions to javax.xml.xquery.XQDynamicContext.
Use method OXQView.getDynamicContext(XQDynamicContext) to obtain access to these extensions. For example:
OXQDataSource ds = new OXQDataSource(); XQConnection con = ds.getConnection(); XQPreparedExpression expr = con.prepareExpression(query); OXQDynamicContext octx = OXQView.getDynamicContext(expr); ...
| Method Summary | |
|---|---|
void |
bindBigDecimal(javax.xml.namespace.QName varName, java.math.BigDecimal value, XQItemType type)Binds a value to the given external variable or the context item. |
void |
bindBigInteger(javax.xml.namespace.QName varName, java.math.BigInteger value, XQItemType type)Binds a value to the given external variable or the context item. |
void |
bindBinary(javax.xml.namespace.QName varName, byte[] value, XQItemType type)Binds a value to the given external variable or the context item. |
void |
bindCalendar(javax.xml.namespace.QName varName, javax.xml.datatype.XMLGregorianCalendar value, XQItemType type)Binds a value to the given external variable or the context item. |
void |
bindDocument(javax.xml.namespace.QName varName, OXQEntity value, XQItemType type)Binds a value to the given external variable or the context item. |
void |
bindDuration(javax.xml.namespace.QName varName, javax.xml.datatype.Duration value, XQItemType type)Binds a value to the given external variable or the context item. |
void |
bindQName(javax.xml.namespace.QName varName, javax.xml.namespace.QName value, XQItemType type)Binds a value to the given external variable or the context item. |
XQConnection |
getConnection()Gets the XQuery connection associated with this dynamic context. |
OXQDebugListener |
getDebugListener()Gets the debug listener. |
java.lang.String |
getDefaultCollection()Gets the default collection that will be used when fn:collection is invoked with no arguments. |
PageManager |
getPageManager()Gets the PageManager. |
int |
getUpdateMode()Gets the default update mode. |
java.lang.Object |
getUserExtension()Returns the user extension. |
XQDynamicContext |
getXQView()Returns the XQDynamicContext instance corresponding to this instance. |
void |
setDebugListener(OXQDebugListener listener)Sets the debug listener. |
void |
setDefaultCollection(java.lang.String uri)Sets the default collection that will be used when fn:collection is invoked with no arguments. |
void |
setPageManager(PageManager pageManager)Sets the PageManager. |
void |
setUpdateMode(int mode)Sets the update mode. |
void |
setUserExtension(java.lang.Object extension)Sets the user extension. |
| Method Detail |
|---|
XQDynamicContext getXQView()
XQDynamicContext instance corresponding to this instance.
XQConnection getConnection()
throws XQException
XQException - if the context is in a closed state
void setDefaultCollection(java.lang.String uri)
throws XQException
fn:collection is invoked with no arguments.uri - the absolute URI of the default collectionXQException - if the URI is not absolute or if the context is in a closed state
java.lang.String getDefaultCollection()
throws XQException
fn:collection is invoked with no arguments.XQException
void setUserExtension(java.lang.Object extension)
throws XQException
OXQFunctionEvaluator.extension - the user extensionXQException
java.lang.Object getUserExtension()
throws XQException
XQException
void bindDocument(javax.xml.namespace.QName varName,
OXQEntity value,
XQItemType type)
throws XQException
If the value represents a well-formed XML document, it results in a document node. The kind of the input type must be null, XQItemType.XQITEMKIND_DOCUMENT_ELEMENT or XQItemType.XQITEMKIND_DOCUMENT_SCHEMA_ELEMENT.
varName - the name of the external variable to bind to, cannot be nullvalue - the value to be converted, cannot be null. The entity must conform to the OXQEntity contract for DOCUMENT entities.type - the type of the value for the created document node. If null is specified, it behaves as if XQDataFactory.createDocumentElementType( XQDataFactory.createElementType(null, XQItemType.XQBASETYPE_XS_UNTYPED)) were passed in as the type parameter. That is, the type represents the XQuery sequence type document-node(element(*, xs:untyped))XQException - if (1) the varName or value argument is null, (2) the conversion of the value to an XDM instance failed, (3) in case of XQPreparedExpression, the dynamic type of the bound value is not compatible with the static type of the variable, (4) in case of an XQPreparedExpression, the variable is not defined in the prolog of the expression, or (5) if the expression is in a closed stateOXQEntity
void bindBigDecimal(javax.xml.namespace.QName varName,
java.math.BigDecimal value,
XQItemType type)
throws XQException
varName - the name of the external variable to bind to, cannot be nullvalue - the value to be convertedtype - the type of the value to be bound to the external variable. The default type of the value is used in case null is specifiedXQException - if (1) the varName argument is null, (2) the conversion of the value to an XDM instance failed, (3) in case of an XQPreparedExpression, the dynamic type of the bound value is not compatible with the static type of the variable, (4) in case of XQPreparedExpression, the variable is not defined in the prolog of the expression, or (5) if the expression is in a closed state
void bindBigInteger(javax.xml.namespace.QName varName,
java.math.BigInteger value,
XQItemType type)
throws XQException
varName - the name of the external variable to bind to, cannot be nullvalue - the value to be convertedtype - the type of the value to be bound to the external variable. The default type of the value is used in case null is specifiedXQException - if (1) the varName argument is null, (2) the conversion of the value to an XDM instance failed, (3) in case of an XQPreparedExpression, the dynamic type of the bound value is not compatible with the static type of the variable, (4) in case of XQPreparedExpression, the variable is not defined in the prolog of the expression, or (5) if the expression is in a closed state
void bindBinary(javax.xml.namespace.QName varName,
byte[] value,
XQItemType type)
throws XQException
varName - the name of the external variable to bind to, cannot be nullvalue - the value to be convertedtype - the type of the value to be bound to the external variable. The default type of the value is used in case null is specifiedXQException - if (1) the varName argument is null, (2) the conversion of the value to an XDM instance failed, (3) in case of XQPreparedExpression, the dynamic type of the bound value is not compatible with the static type of the variable, (4) in case of XQPreparedExpression, the variable is not defined in the prolog of the expression, or (5) if the expression is in a closed state
void bindCalendar(javax.xml.namespace.QName varName,
javax.xml.datatype.XMLGregorianCalendar value,
XQItemType type)
throws XQException
varName - the name of the external variable to bind to, cannot be nullvalue - the value to be convertedtype - the type of the value to be bound to the external variable. The default type of the value is used in case null is specifiedXQException - if (1) the varName argument is null, (2) the conversion of the value to an XDM instance failed, (3) in case of an XQPreparedExpression, the dynamic type of the bound value is not compatible with the static type of the variable, (4) in case of XQPreparedExpression, the variable is not defined in the prolog of the expression, or (5) if the expression is in a closed state
void bindDuration(javax.xml.namespace.QName varName,
javax.xml.datatype.Duration value,
XQItemType type)
throws XQException
varName - the name of the external variable to bind to, cannot be nullvalue - the value to be convertedtype - the type of the value to be bound to the external variable. The default type of the value is used in case null is specifiedXQException - if (1) the varName argument is null, (2) the conversion of the value to an XDM instance failed, (3) in case of an XQPreparedExpression, the dynamic type of the bound value is not compatible with the static type of the variable, (4) in case of XQPreparedExpression, the variable is not defined in the prolog of the expression, or (5) if the expression is in a closed state
void bindQName(javax.xml.namespace.QName varName,
javax.xml.namespace.QName value,
XQItemType type)
throws XQException
varName - the name of the external variable to bind to, cannot be nullvalue - the value to be convertedtype - the type of the value to be bound to the external variable. The default type of the value is used in case null is specifiedXQException - if (1) the varName argument is null, (2) the conversion of the value to an XDM instance failed, (3) in case of an XQPreparedExpression, the dynamic type of the bound value is not compatible with the static type of the variable, (4) in case of XQPreparedExpression, the variable is not defined in the prolog of the expression, or (5) if the expression is in a closed state
void setDebugListener(OXQDebugListener listener)
throws XQException
listener - the debug listenerXQException - if the OXQDataSource property OXQDataSource.DEBUG_MODE is falseOXQDataSource.DEBUG_MODE, OXQDebugListener
OXQDebugListener getDebugListener()
throws XQException
XQException - if the OXQDataSource property OXQDataSource.DEBUG_MODE is falseOXQDataSource.DEBUG_MODE, OXQDebugListener
void setPageManager(PageManager pageManager)
throws XQException
PageManager.pageManager - the page managerXQException - if the OXQDataSource.USE_EXTERNAL_STORAGE property is falseOXQDataSource.USE_EXTERNAL_STORAGE
PageManager getPageManager()
throws XQException
PageManager.XQExceptionOXQDataSource.USE_EXTERNAL_STORAGE
void setUpdateMode(int mode)
throws XQException
OXQConstants.UPDATE_MODE_ENABLED will enable XQuery Update Facility extensions to update XML. Setting the mode to OXQConstants.UPDATE_MODE_DISABLED will prevent XQuery Update Facility extension from updating XML. Note, the transform expression is always enabled regardless of the update mode setting.
The update mode may only be set when the binding mode is XQConstants.BINDING_MODE_DEFERRED.
mode - The update mode, either OXQConstants.UPDATE_MODE_DISABLED or OXQConstants.UPDATE_MODE_ENABLED.XQException - (1) if mode is not OXQConstants.UPDATE_MODE_DISABLED or OXQConstants.UPDATE_MODE_ENABLED (2) if the binding mode is not XQConstants.BINDING_MODE_DEFERREDgetUpdateMode()int getUpdateMode()
OXQConstants.UPDATE_MODE_DISABLED or OXQConstants.UPDATE_MODE_ENABLEDsetUpdateMode(int)
|
Oracle® Database XML Java API Reference 12c Release 1 (12.1) E15981-09 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright © 2003, 2014, Oracle and/or its affiliates. All rights reserved.