|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jetspeed.page.document.CastorFileSystemDocumentHandler
CastorFileSystemDocumentHandler
Field Summary | |
protected String |
documentRoot
|
protected File |
documentRootDir
|
protected String |
documentType
|
protected Class |
expectedReturnType
|
protected org.apache.jetspeed.cache.file.FileCache |
fileCache
|
private org.apache.xml.serialize.OutputFormat |
format
|
private org.apache.jetspeed.page.document.DocumentHandlerFactory |
handlerFactory
|
private static org.apache.commons.logging.Log |
log
|
protected org.exolab.castor.mapping.Mapping |
mapping
the Castor mapping file name |
protected String |
mappingFile
|
private static String |
PSML_DOCUMENT_ENCODING
|
Constructor Summary | |
CastorFileSystemDocumentHandler(String mappingFile,
String documentType,
Class expectedReturnType,
String documentRoot,
org.apache.jetspeed.cache.file.FileCache fileCache)
|
|
CastorFileSystemDocumentHandler(String mappingFile,
String documentType,
String expectedReturnType,
String documentRoot,
org.apache.jetspeed.cache.file.FileCache fileCache)
|
Method Summary | |
protected void |
addToCache(String path,
Object objectToCache)
addToCache |
void |
evict(org.apache.jetspeed.cache.file.FileCacheEntry entry)
evict |
org.apache.jetspeed.om.page.Document |
getDocument(String name)
getDocument |
org.apache.jetspeed.om.page.Document |
getDocument(String name,
boolean fromCache)
getDocument |
org.apache.jetspeed.page.document.DocumentHandlerFactory |
getHandlerFactory()
getHandlerFactory |
String |
getType()
getType |
protected void |
loadMapping()
|
void |
refresh(org.apache.jetspeed.cache.file.FileCacheEntry entry)
refresh |
void |
removeDocument(org.apache.jetspeed.om.page.Document document)
removeDocument |
void |
setHandlerFactory(org.apache.jetspeed.page.document.DocumentHandlerFactory factory)
setHandlerFactory |
protected Object |
unmarshallDocument(Class clazz,
String path,
String extension)
|
void |
updateDocument(org.apache.jetspeed.om.page.Document document)
updateDocument |
protected void |
verifyPath(File path)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final org.apache.commons.logging.Log log
private static final String PSML_DOCUMENT_ENCODING
protected String mappingFile
protected String documentType
protected Class expectedReturnType
protected String documentRoot
protected File documentRootDir
protected org.apache.jetspeed.cache.file.FileCache fileCache
protected org.exolab.castor.mapping.Mapping mapping
private org.apache.xml.serialize.OutputFormat format
private org.apache.jetspeed.page.document.DocumentHandlerFactory handlerFactory
Constructor Detail |
public CastorFileSystemDocumentHandler(String mappingFile, String documentType, Class expectedReturnType, String documentRoot, org.apache.jetspeed.cache.file.FileCache fileCache) throws FileNotFoundException
mappingFile
- Castor mapping file. THe mapping file must be in the class
pathdocumentType
- expectedReturnType
-
FileNotFoundException
public CastorFileSystemDocumentHandler(String mappingFile, String documentType, String expectedReturnType, String documentRoot, org.apache.jetspeed.cache.file.FileCache fileCache) throws FileNotFoundException, ClassNotFoundException
Method Detail |
public org.apache.jetspeed.om.page.Document getDocument(String name) throws org.apache.jetspeed.page.document.NodeException, org.apache.jetspeed.page.document.DocumentNotFoundException
getDocument
getDocument
in interface org.apache.jetspeed.page.document.DocumentHandler
name
-
DocumentException,
- DocumentNotFoundException
org.apache.jetspeed.page.document.NodeException
org.apache.jetspeed.page.document.DocumentNotFoundException
DocumentHandler.getDocument(java.lang.String)
public void updateDocument(org.apache.jetspeed.om.page.Document document) throws org.apache.jetspeed.page.document.FailedToUpdateDocumentException
updateDocument
updateDocument
in interface org.apache.jetspeed.page.document.DocumentHandler
document
-
org.apache.jetspeed.page.document.FailedToUpdateDocumentException
DocumentHandler.updateDocument(org.apache.jetspeed.om.page.Document)
protected void loadMapping()
protected Object unmarshallDocument(Class clazz, String path, String extension) throws org.apache.jetspeed.page.document.NodeNotFoundException, org.apache.jetspeed.page.document.DocumentException
org.apache.jetspeed.page.document.NodeNotFoundException
org.apache.jetspeed.page.document.DocumentException
protected void verifyPath(File path) throws FileNotFoundException
FileNotFoundException
public void removeDocument(org.apache.jetspeed.om.page.Document document) throws org.apache.jetspeed.page.document.DocumentNotFoundException, org.apache.jetspeed.page.document.FailedToDeleteDocumentException
removeDocument
removeDocument
in interface org.apache.jetspeed.page.document.DocumentHandler
document
-
DocumentNotFoundException
FailedToDeleteDocumentException
DocumentHandler.removeDocument(org.apache.jetspeed.om.page.Document)
public org.apache.jetspeed.om.page.Document getDocument(String name, boolean fromCache) throws org.apache.jetspeed.page.document.NodeException
getDocument
getDocument
in interface org.apache.jetspeed.page.document.DocumentHandler
name
-
org.apache.jetspeed.page.document.NodeException
DocumentHandler.getDocument(java.lang.String,
boolean)
protected void addToCache(String path, Object objectToCache)
addToCache
path
- objectToCache
- public void refresh(org.apache.jetspeed.cache.file.FileCacheEntry entry) throws Exception
refresh
refresh
in interface org.apache.jetspeed.cache.file.FileCacheEventListener
entry
-
Exception
FileCacheEventListener.refresh(org.apache.jetspeed.cache.file.FileCacheEntry)
public void evict(org.apache.jetspeed.cache.file.FileCacheEntry entry) throws Exception
evict
evict
in interface org.apache.jetspeed.cache.file.FileCacheEventListener
entry
-
Exception
FileCacheEventListener.evict(org.apache.jetspeed.cache.file.FileCacheEntry)
public String getType()
getType
getType
in interface org.apache.jetspeed.page.document.DocumentHandler
DocumentHandler.getType()
public org.apache.jetspeed.page.document.DocumentHandlerFactory getHandlerFactory()
getHandlerFactory
getHandlerFactory
in interface org.apache.jetspeed.page.document.DocumentHandler
DocumentHandler.getHandlerFactory()
public void setHandlerFactory(org.apache.jetspeed.page.document.DocumentHandlerFactory factory)
setHandlerFactory
setHandlerFactory
in interface org.apache.jetspeed.page.document.DocumentHandler
factory
- DocumentHandler.setHandlerFactory(org.apache.jetspeed.page.document.DocumentHandlerFactory)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |