|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.jetspeed.page.document.psml.CastorFileSystemDocumentHandler
public class CastorFileSystemDocumentHandler
CastorFileSystemDocumentHandler
| Field Summary | |
|---|---|
protected java.lang.String |
documentRoot
|
protected java.io.File |
documentRootDir
|
protected java.lang.String |
documentType
|
protected java.lang.Class |
expectedReturnType
|
protected FileCache |
fileCache
|
| Constructor Summary | |
|---|---|
CastorFileSystemDocumentHandler(java.lang.String mappingFile,
java.lang.String documentType,
java.lang.Class expectedReturnType,
java.lang.String documentRoot,
FileCache fileCache)
|
|
CastorFileSystemDocumentHandler(java.lang.String mappingFile,
java.lang.String documentType,
java.lang.String expectedReturnType,
java.lang.String documentRoot,
FileCache fileCache)
|
|
| Method Summary | |
|---|---|
protected void |
addToCache(java.lang.String path,
java.lang.Object objectToCache)
addToCache |
protected void |
createCastorClassDescriptorResolver(java.lang.String mappingFile)
|
void |
evict(FileCacheEntry entry)
evict |
Document |
getDocument(java.lang.String name)
getDocument |
Document |
getDocument(java.lang.String name,
boolean fromCache)
getDocument |
DocumentHandlerFactory |
getHandlerFactory()
getHandlerFactory |
java.lang.String |
getType()
getType |
void |
refresh(FileCacheEntry entry)
refresh |
void |
removeDocument(Document document)
removeDocument |
void |
setHandlerFactory(DocumentHandlerFactory factory)
setHandlerFactory |
protected java.lang.Object |
unmarshallDocument(java.lang.Class clazz,
java.lang.String path,
java.lang.String extension)
|
void |
updateDocument(Document document)
|
protected void |
updateDocument(Document document,
boolean systemUpdate)
updateDocument |
protected void |
verifyPath(java.io.File path)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.String documentType
protected java.lang.Class expectedReturnType
protected java.lang.String documentRoot
protected java.io.File documentRootDir
protected FileCache fileCache
| Constructor Detail |
|---|
public CastorFileSystemDocumentHandler(java.lang.String mappingFile,
java.lang.String documentType,
java.lang.Class expectedReturnType,
java.lang.String documentRoot,
FileCache fileCache)
throws java.io.FileNotFoundException,
org.xml.sax.SAXException,
javax.xml.parsers.ParserConfigurationException,
org.exolab.castor.mapping.MappingException
mappingFile - Castor mapping file. THe mapping file must be in the class
pathdocumentType - expectedReturnType -
java.io.FileNotFoundException
org.xml.sax.SAXException
javax.xml.parsers.ParserConfigurationException
org.exolab.castor.mapping.MappingException
public CastorFileSystemDocumentHandler(java.lang.String mappingFile,
java.lang.String documentType,
java.lang.String expectedReturnType,
java.lang.String documentRoot,
FileCache fileCache)
throws java.io.FileNotFoundException,
java.lang.ClassNotFoundException,
org.xml.sax.SAXException,
javax.xml.parsers.ParserConfigurationException,
org.exolab.castor.mapping.MappingException
java.io.FileNotFoundException
java.lang.ClassNotFoundException
org.xml.sax.SAXException
javax.xml.parsers.ParserConfigurationException
org.exolab.castor.mapping.MappingException| Method Detail |
|---|
public Document getDocument(java.lang.String name)
throws NodeException,
DocumentNotFoundException
getDocument
getDocument in interface DocumentHandlername -
DocumentException, - DocumentNotFoundException
NodeException
DocumentNotFoundExceptionDocumentHandler.getDocument(java.lang.String)
public void updateDocument(Document document)
throws FailedToUpdateDocumentException
updateDocument in interface DocumentHandlerFailedToUpdateDocumentException
protected void updateDocument(Document document,
boolean systemUpdate)
throws FailedToUpdateDocumentException
updateDocument
document - systemUpdate -
FailedToUpdateDocumentExceptionDocumentHandler.updateDocument(org.apache.jetspeed.om.page.Document)
protected void createCastorClassDescriptorResolver(java.lang.String mappingFile)
throws org.exolab.castor.mapping.MappingException
org.exolab.castor.mapping.MappingException
protected java.lang.Object unmarshallDocument(java.lang.Class clazz,
java.lang.String path,
java.lang.String extension)
throws DocumentNotFoundException,
DocumentException
DocumentNotFoundException
DocumentException
protected void verifyPath(java.io.File path)
throws java.io.FileNotFoundException
java.io.FileNotFoundException
public void removeDocument(Document document)
throws DocumentNotFoundException,
FailedToDeleteDocumentException
removeDocument
removeDocument in interface DocumentHandlerdocument -
DocumentNotFoundException
FailedToDeleteDocumentExceptionDocumentHandler.removeDocument(org.apache.jetspeed.om.page.Document)
public Document getDocument(java.lang.String name,
boolean fromCache)
throws DocumentNotFoundException,
NodeException
getDocument
getDocument in interface DocumentHandlername - fromCahe - Whether or not the Document should be pulled from the cache.
DocumentNotFoundException
NodeExceptionDocumentHandler.getDocument(java.lang.String,
boolean)
protected void addToCache(java.lang.String path,
java.lang.Object objectToCache)
addToCache
path - objectToCache -
public void refresh(FileCacheEntry entry)
throws java.lang.Exception
refresh
refresh in interface FileCacheEventListenerentry -
java.lang.ExceptionFileCacheEventListener.refresh(org.apache.jetspeed.cache.file.FileCacheEntry)
public void evict(FileCacheEntry entry)
throws java.lang.Exception
evict
evict in interface FileCacheEventListenerentry -
java.lang.ExceptionFileCacheEventListener.evict(org.apache.jetspeed.cache.file.FileCacheEntry)public java.lang.String getType()
getType
getType in interface DocumentHandlerDocumentHandler.getType()public DocumentHandlerFactory getHandlerFactory()
getHandlerFactory
getHandlerFactory in interface DocumentHandlerDocumentHandler.getHandlerFactory()public void setHandlerFactory(DocumentHandlerFactory factory)
setHandlerFactory
setHandlerFactory in interface DocumentHandlerfactory - DocumentHandler.setHandlerFactory(org.apache.jetspeed.page.document.DocumentHandlerFactory)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||