org.nuxeo.ecm.platform.convert.plugins
Class ZipCachableBlobHolder
java.lang.Object
org.nuxeo.ecm.core.api.blobholder.AbstractBlobHolder
org.nuxeo.ecm.core.api.blobholder.SimpleBlobHolder
org.nuxeo.ecm.core.convert.cache.SimpleCachableBlobHolder
org.nuxeo.ecm.platform.convert.plugins.ZipCachableBlobHolder
- All Implemented Interfaces:
- BlobHolder, CachableBlobHolder
public class ZipCachableBlobHolder
- extends SimpleCachableBlobHolder
Cachable implementation of a zip file.
- Author:
- Laurent Doguin
ZipCachableBlobHolder
public ZipCachableBlobHolder()
ZipCachableBlobHolder
public ZipCachableBlobHolder(Blob zipBlob)
getBlob
public Blob getBlob(String path)
throws IOException,
MimetypeNotFoundException,
MimetypeDetectionException,
ConversionException
- Throws:
IOException
MimetypeNotFoundException
MimetypeDetectionException
ConversionException
getBlob
public Blob getBlob()
throws ClientException
- Description copied from interface:
BlobHolder
- Returns the Blob held inside the object.
- Specified by:
getBlob
in interface BlobHolder
- Overrides:
getBlob
in class SimpleBlobHolder
- Throws:
ClientException
getBlobs
public List<Blob> getBlobs()
throws ClientException
- Description copied from interface:
BlobHolder
- Returns a list of blobs, if holder implementation supports multiple
blobs.
- Specified by:
getBlobs
in interface BlobHolder
- Overrides:
getBlobs
in class SimpleBlobHolder
- Throws:
ClientException
load
public void load(String path)
- Description copied from interface:
CachableBlobHolder
- Reloads the
BlobHolder
from a file.
- Specified by:
load
in interface CachableBlobHolder
- Overrides:
load
in class SimpleCachableBlobHolder
addDirectoryToList
public void addDirectoryToList(File directory,
String prefix)
throws ConversionException
- Overrides:
addDirectoryToList
in class SimpleCachableBlobHolder
- Throws:
ConversionException
persist
public String persist(String basePath)
throws Exception
- Description copied from interface:
CachableBlobHolder
- Persists the blobHolder to disk.
- Specified by:
persist
in interface CachableBlobHolder
- Overrides:
persist
in class SimpleCachableBlobHolder
- Parameters:
basePath
- the base path (existing directory) as determined by the caller
- Returns:
- the full path of the newly created FileSystem resource
- Throws:
Exception
getMimeType
public String getMimeType(File file)
throws ConversionException
- Throws:
ConversionException
getMimeTypeService
public MimetypeRegistry getMimeTypeService()
throws ConversionException
- Throws:
ConversionException
Copyright © 2011 Nuxeo SAS. All Rights Reserved.