Package digilib.io
Class ImageCacheStream
- java.lang.Object
-
- digilib.io.ImageInput
-
- digilib.io.ImageStream
-
- digilib.io.ImageCacheStream
-
public class ImageCacheStream extends ImageStream
- Author:
- casties
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class digilib.io.ImageInput
ImageInput.InputTag
-
-
Field Summary
Fields Modifier and Type Field Description protected ImageInputStream
iis
-
Fields inherited from class digilib.io.ImageStream
stream
-
Fields inherited from class digilib.io.ImageInput
mimetype, pixelSize, tags, tileSize
-
-
Constructor Summary
Constructors Constructor Description ImageCacheStream(InputStream stream, String mimeType)
Create ImageCacheStream from InputStream and mime-type.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ImageInputStream
getImageInputStream()
Returns the input as ImageInputStream (if available)boolean
hasImageInputStream()
Returns if the input can be returned as ImageInputStream.void
setInputStream(InputStream stream)
-
Methods inherited from class digilib.io.ImageStream
getInputStream, hasInputStream
-
Methods inherited from class digilib.io.ImageInput
getAspect, getFile, getMimetype, getSize, getTags, getTileSize, hasFile, hasMimetype, hasTag, isChecked, setMimetype, setSize, setTag, setTags, setTileSize
-
-
-
-
Field Detail
-
iis
protected ImageInputStream iis
-
-
Constructor Detail
-
ImageCacheStream
public ImageCacheStream(InputStream stream, String mimeType) throws IOException
Create ImageCacheStream from InputStream and mime-type.- Parameters:
stream
- the InputStreammimeType
- the mime-type- Throws:
IOException
- on error
-
-
Method Detail
-
hasImageInputStream
public boolean hasImageInputStream()
Description copied from class:ImageInput
Returns if the input can be returned as ImageInputStream.- Overrides:
hasImageInputStream
in classImageInput
- Returns:
- has ImageInputStream
-
getImageInputStream
public ImageInputStream getImageInputStream()
Description copied from class:ImageInput
Returns the input as ImageInputStream (if available)- Overrides:
getImageInputStream
in classImageInput
- Returns:
- the ImageInputStream
-
setInputStream
public void setInputStream(InputStream stream)
- Overrides:
setInputStream
in classImageStream
- Parameters:
stream
- the stream to set
-
-