|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Datastore
Interface for interacting with a backend data store.
Field Summary | |
---|---|
static java.lang.String |
ATTR_REQUEST_PATCH_OPS
Request attribute to store the Patch Operations Request Attribute |
static java.lang.String |
ATTR_REQUEST_UPDATED_DOC
Request attribute to store the updated document from a Node Selector PUT or DELETE |
static java.lang.String |
ATTR_USER_TRANSACTION
Request attribute to store the datastore's UserTransaction object |
static java.lang.String |
COPYRIGHT
|
static java.lang.String |
PATCH_OPS_ADD
Patch Operations Add Value |
static java.lang.String |
PATCH_OPS_REMOVE
Patch Operations Remove Value |
static java.lang.String |
PATCH_OPS_REPLACE
Path Operations Replace Value |
Method Summary | |
---|---|
java.lang.String |
buildSipXQuery(java.lang.String defaultNamespace,
java.lang.String table,
java.lang.String serviceUri,
boolean includePresPack)
Used by RlsXdmSipServlet class |
java.lang.String |
buildUriXQuery(java.lang.String defaultNamespace,
java.lang.String table,
java.lang.String serviceUri)
Used by ResourceListConstraintFilter class |
void |
commitTransaction(XcapServerRequest request)
Commits the transaction associated with the Datastore |
long |
delete(XcapServerRequest request,
XcapServerResponse response)
Deletes a document |
java.lang.String |
get(com.ibm.xcap.DocumentSelector documentSelector)
Retrieves a document |
java.lang.String |
get(com.ibm.xcap.DocumentSelector documentSelector,
java.security.Principal principal,
boolean isSuperAdminUser,
boolean isAnonymousUser)
Retrieves a document |
java.util.Map<java.lang.String,java.lang.String> |
get(java.util.List<java.lang.String> documentSelectors,
java.lang.String baseXPath,
java.util.List<java.lang.String> additionalXPaths)
Retrieves a Map of xml fragments based on a list of document selectors and associated XPath statements |
java.util.Map<java.lang.String,java.lang.String> |
get(java.util.List<java.lang.String> documentSelectors,
java.lang.String baseXPath,
java.util.List<java.lang.String> additionalXPaths,
java.util.Map<java.lang.String,java.lang.String> additionalNamespaces,
java.lang.String returnXPath)
Retrieves a Map of xml fragments based on a list of document selectors and associated XPath statements |
java.lang.String |
get(XcapServerRequest request,
XcapServerResponse response)
Retrieves a document |
long |
getETag(java.lang.String documentSelector,
javax.servlet.sip.SipServletRequest request)
Retrieves the ETag for a document |
long |
getETag(java.lang.String documentSelector,
XcapServerRequest request)
Retrieves the ETag for a document |
javax.transaction.UserTransaction |
getTransaction(XcapServerRequest request)
Returns the current transaction for this request. |
java.lang.String |
getXmlDocumentsDirectory(java.lang.String uri)
Retreives the XML Documents Directory for the configured AUID |
java.lang.String |
getXmlDocumentsDirectory(XcapServerRequest request)
Retreives the XML Documents Directory for the configured AUID |
long |
put(XcapServerRequest request,
XcapServerResponse response)
Puts a document |
long |
put(XcapServerRequest request,
XcapServerResponse response,
DatastoreHelper dh,
java.sql.Connection con)
Puts a document |
void |
rollbackTransaction(XcapServerRequest request)
Rolls back the transaction associated with the Datastore |
com.ibm.xcap.DocumentSelector |
transformGlobalIndexDocumentSelector(com.ibm.xcap.DocumentSelector documentSelector)
Transforms a DocumentSelector for a global/index file to a DocumentSelector for an individual file |
com.ibm.xcap.DocumentSelector |
transformNodeAttribute(com.ibm.xcap.DocumentSelector documentSelector)
Transforms the nodeAttribute of a DocumentSelector to match the format for |
java.util.List<java.lang.String> |
xquery(java.lang.String query,
ApplicationUsage appUsage)
Performs an XQuery |
java.lang.String |
xquery(XcapServerRequest request,
XcapServerResponse response)
Performs an XQuery based on a search request from a client |
Methods inherited from interface com.ibm.xdms.function.Function |
---|
getApplicationUsage, init |
Field Detail |
---|
static final java.lang.String COPYRIGHT
static final java.lang.String ATTR_REQUEST_PATCH_OPS
static final java.lang.String PATCH_OPS_ADD
static final java.lang.String PATCH_OPS_REMOVE
static final java.lang.String PATCH_OPS_REPLACE
static final java.lang.String ATTR_REQUEST_UPDATED_DOC
static final java.lang.String ATTR_USER_TRANSACTION
Method Detail |
---|
java.lang.String get(XcapServerRequest request, XcapServerResponse response) throws XdmsException
request
- XcapServerRequestresponse
- XcapServerResponse, if it is not null
,
then this method will set the document, status code, and ETag
XcapException
- error retrieving the document from the database
XdmsException
java.lang.String get(com.ibm.xcap.DocumentSelector documentSelector) throws XcapException
documentSelector
- DocumentSelector
XcapException
- error retrieving the document from the databasejava.lang.String get(com.ibm.xcap.DocumentSelector documentSelector, java.security.Principal principal, boolean isSuperAdminUser, boolean isAnonymousUser) throws XcapException, XdmsException, java.net.MalformedURLException
documentSelector
- DocumentSelector
XcapException
- error retrieving the document from the database
XdmsException
java.net.MalformedURLException
com.ibm.xcap.DocumentSelector transformGlobalIndexDocumentSelector(com.ibm.xcap.DocumentSelector documentSelector) throws LocalConstraintFailureException, XcapException, java.net.MalformedURLException
documentSelector
- DocumentSelector
LocalConstraintFailureException,
- XcapException, MalformedURLException
LocalConstraintFailureException
XcapException
java.net.MalformedURLException
com.ibm.xcap.DocumentSelector transformNodeAttribute(com.ibm.xcap.DocumentSelector documentSelector) throws java.net.MalformedURLException, XcapException
documentSelector
- DocumentSelector
XcapException,
- MalformedURLException
java.net.MalformedURLException
XcapException
long delete(XcapServerRequest request, XcapServerResponse response) throws CannotDeleteException, XcapException
request
- XcapServerRequestresponse
- XcapServerResponse, if it is not null
,
then this method will set the status code and ETag
CannotDeleteException
- document could not be deleted
XcapException
long put(XcapServerRequest request, XcapServerResponse response) throws CannotInsertException, XcapException
request
- XcapServerRequestresponse
- XcapServerResponse, if it is not null
,
then this method will set the status code and ETag
CannotInsertException
- if the document could not be inserted
XcapException
long put(XcapServerRequest request, XcapServerResponse response, DatastoreHelper dh, java.sql.Connection con) throws CannotInsertException, XcapException
request
- XcapServerRequestresponse
- XcapServerResponse, if it is not null
,
then this method will set the status code and ETag
CannotInsertException
- if the document could not be inserted
XcapException
long getETag(java.lang.String documentSelector, XcapServerRequest request) throws XcapException
documentSelector
- Document Selector
XcapException
- error retrieving the document from the databaselong getETag(java.lang.String documentSelector, javax.servlet.sip.SipServletRequest request) throws XcapException
documentSelector
- Document Selector
XcapException
- error retrieving the document from the databasejava.util.List<java.lang.String> xquery(java.lang.String query, ApplicationUsage appUsage) throws XcapException
query
- XQuery stringappUsage
- Application Usage
XcapException
- error retrieving the document from the databasejava.lang.String xquery(XcapServerRequest request, XcapServerResponse response) throws XdmsException
request
- XcapServerRequestresponse
- XcapServerResponse
XdmsException
java.lang.String buildSipXQuery(java.lang.String defaultNamespace, java.lang.String table, java.lang.String serviceUri, boolean includePresPack) throws java.net.MalformedURLException
defaultNamespace
- table
- serviceUri
-
java.net.MalformedURLException
java.lang.String buildUriXQuery(java.lang.String defaultNamespace, java.lang.String table, java.lang.String serviceUri) throws java.net.MalformedURLException
defaultNamespace
- table
- serviceUri
-
java.net.MalformedURLException
java.util.Map<java.lang.String,java.lang.String> get(java.util.List<java.lang.String> documentSelectors, java.lang.String baseXPath, java.util.List<java.lang.String> additionalXPaths) throws XcapException
documentSelectors
- Document Selectors to look forbaseXPath
- Base XPath statement to use in the documentadditionalXPaths
- XPath statements which will be applied on top of
the baseXPath statement
XcapException
- Error interacting with the databasejava.util.Map<java.lang.String,java.lang.String> get(java.util.List<java.lang.String> documentSelectors, java.lang.String baseXPath, java.util.List<java.lang.String> additionalXPaths, java.util.Map<java.lang.String,java.lang.String> additionalNamespaces, java.lang.String returnXPath) throws XcapException
documentSelectors
- Document Selectors to look forbaseXPath
- Base XPath statement to use in the documentadditionalXPaths
- XPath statements which will be applied on top of
the baseXPath statementadditionalNamespaces
- Map of additional namespace URLs, keyed by
their prefixesreturnXPath
- return XPath, this is appended to the baseXPath
statement
XcapException
- Error interacting with the databasevoid commitTransaction(XcapServerRequest request) throws XcapException
request
- XcapServerRequest object
XcapException
void rollbackTransaction(XcapServerRequest request) throws XcapException
request
- XcapServerRequest object
XcapException
javax.transaction.UserTransaction getTransaction(XcapServerRequest request) throws XcapException
request
- XcapServerRequest
XcapException
java.lang.String getXmlDocumentsDirectory(XcapServerRequest request) throws XdmsException
request
- XcapServerRequest
XdmsException
- Error retrieving the directory for the configured
AUIDjava.lang.String getXmlDocumentsDirectory(java.lang.String uri) throws XdmsException, java.net.MalformedURLException
uri
- String
XdmsException
- Error retrieving the directory for the configured
AUID
java.net.MalformedURLException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |