public class ThumbnailService extends AbstractFileSystemService
FILES_PATH, PIXELS_PATH, ROOT_DEFAULT, THUMBNAILS_PATH| Constructor and Description |
|---|
ThumbnailService(String path)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
createThumbnail(Thumbnail thumbnail,
byte[] buf)
Creates thumbnail on disk using byte array
|
byte[] |
getThumbnail(Thumbnail thumbnail)
Return byte array of Thumbnail
|
byte[] |
getThumbnail(Thumbnail thumbnail,
byte[] buf)
Return byte array of Thumbnail, providing byte array
|
boolean |
getThumbnailExists(Thumbnail thumbnail)
Returns whether or not a thumbnail exists on disk.
|
long |
getThumbnailLength(Thumbnail thumbnail)
Returns length of Thumbnail on disk
|
FileOutputStream |
getThumbnailOutputStream(Thumbnail thumbnail)
Return FileOutputStream of Thumbnail
|
void |
removeThumbnails(List<Long> thumbnailIds)
Removes files from data repository based on a parameterized List of Long
thumbnail ids
|
createSubpath, getFilesPath, getPixelsPath, getThumbnailPathpublic ThumbnailService(String path)
path - public void createThumbnail(Thumbnail thumbnail, byte[] buf) throws IOException
thumbnail - buf - IOExceptionpublic long getThumbnailLength(Thumbnail thumbnail)
thumbnail - public byte[] getThumbnail(Thumbnail thumbnail) throws IOException
thumbnail - IOExceptionpublic byte[] getThumbnail(Thumbnail thumbnail, byte[] buf) throws IOException
thumbnail - buf - IOExceptionpublic FileOutputStream getThumbnailOutputStream(Thumbnail thumbnail) throws IOException
thumbnail - FileOutputStreamIOExceptionpublic boolean getThumbnailExists(Thumbnail thumbnail) throws IOException
thumbnail - The thumbnail metadata.IOExceptionpublic void removeThumbnails(List<Long> thumbnailIds)
thumbnailIds - -
Long file keys to be deletedResourceError - If deletion fails.
Version: 5.2.6-ice35-b35
Copyright © 2016 The University of Dundee & Open Microscopy Environment. All Rights Reserved.