Package org.nuxeo.ecm.core.convert.cache
Interface CachableBlobHolder
-
- All Superinterfaces:
BlobHolder
- All Known Implementing Classes:
SimpleCachableBlobHolder
,ZipCachableBlobHolder
public interface CachableBlobHolder extends BlobHolder
Extended interface forBlobHolder
that can be cached.A BlobHolder can be cached if it can be persisted to disk and reloaded from a file. Converters need to return BlobHolders that implement this interface to make the result cachable.
- Author:
- tiry
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
load(String path)
Reloads theBlobHolder
from a file.String
persist(String basePath)
Persists the blobHolder to disk.-
Methods inherited from interface org.nuxeo.ecm.core.api.blobholder.BlobHolder
getBlob, getBlobs, getFilePath, getHash, getModificationDate, getProperties, getProperty, setBlob
-
-
-
-
Method Detail
-
persist
String persist(String basePath) throws IOException
Persists the blobHolder to disk.- Parameters:
basePath
- the base path (existing directory) as determined by the caller- Returns:
- the full path of the newly created FileSystem resource
- Throws:
IOException
-
load
void load(String path) throws IOException
Reloads theBlobHolder
from a file.- Throws:
IOException
-
-