Berkeley DB XML
version 2.5.16

com.sleepycat.dbxml
Class XmlDocumentConfig

java.lang.Object
  extended by com.sleepycat.dbxml.XmlDocumentConfig
All Implemented Interfaces:
Cloneable

public class XmlDocumentConfig
extends Object
implements Cloneable

Used to configure operations that operate on XmlDocument objects.


Field Summary
static XmlDocumentConfig DEFAULT
          The default settings.
 
Constructor Summary
XmlDocumentConfig()
           
 
Method Summary
 boolean getAutoCommit()
          Returns whether the operation will auto-commit if no transaction is provided.
 boolean getCacheDocuments()
          Returns whether the use of a cache mechanism has been enabled.
 boolean getDocumentProjection()
          Gets whether document projection will be applied to document parsing done in the operation.
 boolean getDocumentsOnly()
          Gets whether index lookups will return documents or nodes for containers with node indexes.
 boolean getGenerateName()
          Gets whether to automatically generate a name for the document.
 boolean getLazyDocs()
          Gets whether to retrieve the document lazily.
 LockMode getLockMode()
          Get the lock mode for the operation.
 boolean getReverseOrder()
          Gets whether to sort index lookups in reverse order
 boolean getWellFormedOnly()
          Gets whether operations that may parse a document use only a well-formed scanner, avoiding the expense of reading any referenced schema or DTD.
 XmlDocumentConfig setAutoCommit(boolean value)
          Sets whether the operation will auto-commit if no transaction is provided.
 XmlDocumentConfig setCacheDocuments(boolean value)
          Sets whether a cache mechanism is enabled.
 XmlDocumentConfig setDocumentProjection(boolean value)
          Sets whether to use document projection on document parsing operations performed.
 XmlDocumentConfig setDocumentsOnly(boolean value)
          Sets whether index lookups will return documents or nodes for containers with node indexes.
 XmlDocumentConfig setGenerateName(boolean value)
          Sets whether to automatically generate a name for the document.
 XmlDocumentConfig setLazyDocs(boolean value)
          Sets whether to retrieve the document lazily.
 XmlDocumentConfig setLockMode(LockMode lmode)
          Set the lock mode for the operation.
 XmlDocumentConfig setReverseOrder(boolean value)
          Sets whether to sort index lookups in reverse order
 XmlDocumentConfig setWellFormedOnly(boolean value)
          Sets whether operations that may parse a document use only a well-formed scanner, avoiding the expense of reading any referenced schema or DTD.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT

public static final XmlDocumentConfig DEFAULT
The default settings.

Constructor Detail

XmlDocumentConfig

public XmlDocumentConfig()
Method Detail

getDocumentsOnly

public boolean getDocumentsOnly()
Gets whether index lookups will return documents or nodes for containers with node indexes.


setDocumentsOnly

public XmlDocumentConfig setDocumentsOnly(boolean value)
Sets whether index lookups will return documents or nodes for containers with node indexes.


getDocumentProjection

public boolean getDocumentProjection()
Gets whether document projection will be applied to document parsing done in the operation.


setDocumentProjection

public XmlDocumentConfig setDocumentProjection(boolean value)
Sets whether to use document projection on document parsing operations performed. Document projection uses static analysis of the query to materialize only those portions of the document relevant to the query, which can significantly enhance performance of queries against documents from containers of type XmlContainer.WholedocContainer and documents not in a container. It should not be used if arbitrary navigation of the resulting nodes is to be performed, as not all nodes in the original document will be present and unexepcted results could be returned. This flag has no effect on documents in containers of type XmlContainer.NodeContainer.


getAutoCommit

public boolean getAutoCommit()
Returns whether the operation will auto-commit if no transaction is provided. The default is true.


setAutoCommit

public XmlDocumentConfig setAutoCommit(boolean value)
Sets whether the operation will auto-commit if no transaction is provided. The default is true, and this parameter can only be set to false if the XmlDocumentConfig object is an argument to XmlQueryExpression.execute(com.sleepycat.dbxml.XmlQueryContext)


getCacheDocuments

public boolean getCacheDocuments()
Returns whether the use of a cache mechanism has been enabled. The default is false.


setCacheDocuments

public XmlDocumentConfig setCacheDocuments(boolean value)
Sets whether a cache mechanism is enabled. The default is false, and this parameter can only be set to true if the XmlDocumentConfig object is an argument to XmlIndexLookup.execute(com.sleepycat.dbxml.XmlQueryContext)


getLazyDocs

public boolean getLazyDocs()
Gets whether to retrieve the document lazily.


setLazyDocs

public XmlDocumentConfig setLazyDocs(boolean value)
Sets whether to retrieve the document lazily. That is, retrieve document content and document metadata only on an as needed basis when reading the document.


getGenerateName

public boolean getGenerateName()
Gets whether to automatically generate a name for the document.


setGenerateName

public XmlDocumentConfig setGenerateName(boolean value)
Sets whether to automatically generate a name for the document.


getReverseOrder

public boolean getReverseOrder()
Gets whether to sort index lookups in reverse order


setReverseOrder

public XmlDocumentConfig setReverseOrder(boolean value)
Sets whether to sort index lookups in reverse order


getLockMode

public LockMode getLockMode()
Get the lock mode for the operation.


setLockMode

public XmlDocumentConfig setLockMode(LockMode lmode)
Set the lock mode for the operation.


getWellFormedOnly

public boolean getWellFormedOnly()
Gets whether operations that may parse a document use only a well-formed scanner, avoiding the expense of reading any referenced schema or DTD.


setWellFormedOnly

public XmlDocumentConfig setWellFormedOnly(boolean value)
Sets whether operations that may parse a document use only a well-formed scanner, avoiding the expense of reading any referenced schema or DTD.


Berkeley DB XML
version 2.5.16

Copyright (c) 1996,2009 Oracle. All rights reserved.