uk.co.lakesidetech.springxmldb.processor
Class XMLDBExportProcessor
java.lang.Object
uk.co.lakesidetech.springxmldb.processor.XMLDBExportProcessor
- public class XMLDBExportProcessor
- extends java.lang.Object
The XMLDBExportProcessor
is used to export the contents of an XML database to a filesystem
location. This works for both XML and binary resources and allows for recursive collection traversing
for conversion to directory structures. The resources have a file name of their database resource ID
- Author:
- Stuart Eccles
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XMLDBExportProcessor
public XMLDBExportProcessor()
setCollectionManageDao
public void setCollectionManageDao(ICollectionManageXMLDBDao collectionManageDao)
- Parameters:
collectionManageDao
- The collectionManageDao to set.
setXmldbManageDao
public void setXmldbManageDao(IResourceManageXMLDBDao xmldbManageDao)
- Parameters:
xmldbManageDao
- The xmldbManageDao to set.
exportCollection
public java.util.Map exportCollection(java.io.File directory,
java.lang.String collectionPath,
boolean recursive)
throws java.io.IOException,
XMLDBDataAccessException
- Export an XML database collection to a filesystem directory. If the recursive flag
is specified the exported will convert collections to directories.
- Parameters:
directory
- The directory to export tocollectionPath
- The collection path to export fromrecursive
- transverse the collection tree converting collections into directories
- Returns:
- A Map of collectionpaths to Sets of ids of resources exported
- Throws:
java.io.IOException
- problems with file writing
XMLDBDataAccessException
- problems with XML database access