uk.co.lakesidetech.springxmldb.dao
Class BaseXUpdateXMLDBDao
java.lang.Object
uk.co.lakesidetech.springxmldb.dao.AbstractXMLDBDao
uk.co.lakesidetech.springxmldb.dao.BaseXUpdateXMLDBDao
- All Implemented Interfaces:
- IXUpdateXMLDBDao
- public class BaseXUpdateXMLDBDao
- extends AbstractXMLDBDao
- implements IXUpdateXMLDBDao
Implementation of IXUpdateXMLDBDao using XML:DB apis to be reusable across
any XML database which supports a pure XML:DB api.
- Author:
- Stuart Eccles
|
Method Summary |
protected org.xmldb.api.modules.XUpdateQueryService |
getXUpdateQueryServiceFromCollection(org.xmldb.api.base.Collection collection)
Get the XML:DB XUpdateQueryService for a specified collection |
void |
updateResourceWithXUpdate(java.lang.String xUpdate,
java.lang.String resourceId,
java.lang.String collectionPath)
updates a specific resource with an xupdate string |
void |
updateWithXUpdate(java.lang.String xUpdate,
java.lang.String collectionPath)
update items within a collection with a specific Xupdate string |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BaseXUpdateXMLDBDao
public BaseXUpdateXMLDBDao()
getXUpdateQueryServiceFromCollection
protected org.xmldb.api.modules.XUpdateQueryService getXUpdateQueryServiceFromCollection(org.xmldb.api.base.Collection collection)
throws org.xmldb.api.base.XMLDBException
- Get the XML:DB XUpdateQueryService for a specified collection
- Parameters:
collection - the XML:DB collection object
- Returns:
- the XUpdate service
- Throws:
org.xmldb.api.base.XMLDBException - if the service cannot be found
updateWithXUpdate
public void updateWithXUpdate(java.lang.String xUpdate,
java.lang.String collectionPath)
throws XMLDBDataAccessException
- update items within a collection with a specific Xupdate string
- Specified by:
updateWithXUpdate in interface IXUpdateXMLDBDao
- Parameters:
xUpdate - the XUpdate string to usecollectionPath - The
- Throws:
XMLDBDataAccessException- See Also:
IXUpdateXMLDBDao.updateWithXUpdate(java.lang.String, java.lang.String)
updateResourceWithXUpdate
public void updateResourceWithXUpdate(java.lang.String xUpdate,
java.lang.String resourceId,
java.lang.String collectionPath)
throws XMLDBDataAccessException
- updates a specific resource with an xupdate string
- Specified by:
updateResourceWithXUpdate in interface IXUpdateXMLDBDao
- Parameters:
xUpdate - the xupdate string to runresourceId - the resource to updatecollectionPath - the collection the resource is in
- Throws:
XMLDBDataAccessException - if anything goes wrong with the data access- See Also:
IXUpdateXMLDBDao.updateResourceWithXUpdate(java.lang.String, java.lang.String, java.lang.String)