org.exist.xquery
Class ModuleContext

java.lang.Object
  extended byorg.exist.xquery.XQueryContext
      extended byorg.exist.xquery.ModuleContext

public class ModuleContext
extends XQueryContext

Subclass of XQueryContext for imported modules.

Author:
wolf

Field Summary
 
Fields inherited from class org.exist.xquery.XQueryContext
baseURI, baseURISetInProlog, broker, contextStack, declaredFunctions, defaultFunctionNamespace, forwardReferences, globalVariables, inScopeNamespaces, inScopePrefixes, lastVar, moduleLoadPath, modules, namespaces, namespaceStack, pragmas, prefixes, staticDocumentPaths, staticDocuments, variableStackSize, watchdog, XQUERY_LOCAL_NS
 
Constructor Summary
ModuleContext(XQueryContext parentContext)
           
 
Method Summary
protected  void clearUpdateListeners()
           
 java.lang.String getBaseURI()
          Get the base URI of the evaluation context.
 DBBroker getBroker()
          Get the DBBroker instance used for the current query.
 MemTreeBuilder getDocumentBuilder()
          Get the document builder currently used for creating temporary document fragments.
 Module getModule(java.lang.String namespaceURI)
          Get the built-in module registered for the given namespace URI.
 java.util.Iterator getModules()
          Return an iterator over all built-in modules currently registered.
 DocumentSet getStaticallyKnownDocuments()
          Get the set of statically known documents.
 XQueryWatchDog getWatchDog()
           
 void popDocumentContext()
           
 void pushDocumentContext()
          Push any document fragment created within the current execution context on the stack.
 void registerUpdateListener(UpdateListener listener)
           
 void setBaseURI(java.lang.String uri)
          Set the base URI for the evaluation context.
 
Methods inherited from class org.exist.xquery.XQueryContext
addForwardReference, addPragma, checkModulesValid, clearNamespaces, declareFunction, declareGlobalVariable, declareInScopeNamespace, declareNamespace, declareNamespaces, declareVariable, declareVariableBinding, getAccessContext, getCollator, getContextPosition, getCurrentStackSize, getDefaultCollation, getDefaultCollator, getDefaultFunctionNamespace, getExpressionCount, getLockedDocuments, getModuleLoadPath, getPDP, getPragma, getPrefixForURI, getProfiler, getRootExpression, getSignaturesForFunction, getURIForPrefix, getUser, getXQueryContextVar, importModule, isBackwardsCompatible, isProfilingEnabled, isProfilingEnabled, isVarDeclared, loadBuiltInModule, loadDefaults, localFunctions, lockDocumentsOnLoad, markLocalVariables, nextExpressionId, popInScopeNamespaces, popLocalVariables, popNamespaceContext, proceed, proceed, proceed, pushInScopeNamespaces, pushNamespaceContext, recover, releaseLockedDocuments, releaseUnusedDocuments, removeNamespace, reset, resolveForwardReferences, resolveFunction, resolveVariable, resolveVariable, setBackwardsCompatibility, setBaseURI, setBroker, setContextPosition, setDefaultCollation, setDefaultFunctionNamespace, setLockDocumentsOnLoad, setModuleLoadPath, setRootExpression, setStaticallyKnownDocuments, setStaticallyKnownDocuments, setStripWhitespace, setWatchDog, setXQueryContextVar, setXQuerySerializer, storeTemporaryDoc, stripWhitespace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ModuleContext

public ModuleContext(XQueryContext parentContext)
Method Detail

getStaticallyKnownDocuments

public DocumentSet getStaticallyKnownDocuments()
                                        throws XPathException
Description copied from class: XQueryContext
Get the set of statically known documents.

Overrides:
getStaticallyKnownDocuments in class XQueryContext
Returns:
Throws:
XPathException

getModule

public Module getModule(java.lang.String namespaceURI)
Description copied from class: XQueryContext
Get the built-in module registered for the given namespace URI.

Overrides:
getModule in class XQueryContext
Parameters:
namespaceURI -
Returns:

getModules

public java.util.Iterator getModules()
Description copied from class: XQueryContext
Return an iterator over all built-in modules currently registered.

Overrides:
getModules in class XQueryContext
Returns:

getWatchDog

public XQueryWatchDog getWatchDog()
Overrides:
getWatchDog in class XQueryContext

getBaseURI

public java.lang.String getBaseURI()
Description copied from class: XQueryContext
Get the base URI of the evaluation context. This is the URI returned by the fn:base-uri() function.

Overrides:
getBaseURI in class XQueryContext
Returns:

setBaseURI

public void setBaseURI(java.lang.String uri)
Description copied from class: XQueryContext
Set the base URI for the evaluation context. This is the URI returned by the fn:base-uri() function.

Overrides:
setBaseURI in class XQueryContext
Parameters:
uri -

getBroker

public DBBroker getBroker()
Description copied from class: XQueryContext
Get the DBBroker instance used for the current query. The DBBroker is the main database access object, providing access to all internal database functions.

Overrides:
getBroker in class XQueryContext
Returns:

getDocumentBuilder

public MemTreeBuilder getDocumentBuilder()
Description copied from class: XQueryContext
Get the document builder currently used for creating temporary document fragments. A new document builder will be created on demand.

Overrides:
getDocumentBuilder in class XQueryContext
Returns:

pushDocumentContext

public void pushDocumentContext()
Description copied from class: XQueryContext
Push any document fragment created within the current execution context on the stack.

Overrides:
pushDocumentContext in class XQueryContext

popDocumentContext

public void popDocumentContext()
Overrides:
popDocumentContext in class XQueryContext

registerUpdateListener

public void registerUpdateListener(UpdateListener listener)
Overrides:
registerUpdateListener in class XQueryContext

clearUpdateListeners

protected void clearUpdateListeners()
Overrides:
clearUpdateListeners in class XQueryContext


<oXygen/> XML Editor provides support for editing and debugging XQuery expressions against the eXist XML Database.