|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.coobird.thumbnailator.tasks.io.FileImageSource
public class FileImageSource
An ImageSource which reads the source image from a file.
| Constructor Summary | |
|---|---|
FileImageSource(File sourceFile)
Instantiates a FileImageSource with the specified file as
the source image. |
|
FileImageSource(String sourceFilePath)
Instantiates a FileImageSource with the specified file as
the source image. |
|
| Method Summary | |
|---|---|
String |
getInputFormatName()
Returns the name of the image format. |
File |
getSource()
Returns the source file from which an image is read. |
BufferedImage |
read()
Retrieves the image from the source. |
void |
setThumbnailParameter(ThumbnailParameter param)
Sets the ThumbnailParameter from which to retrieve parameters
to use when retrieving the image. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FileImageSource(File sourceFile)
FileImageSource with the specified file as
the source image.
sourceFile - The source image file.
NullPointerException - If the image is null.public FileImageSource(String sourceFilePath)
FileImageSource with the specified file as
the source image.
sourceFilePath - The filepath of the source image file.
NullPointerException - If the image is null.| Method Detail |
|---|
public BufferedImage read()
throws IOException
ImageSource
read in interface ImageSource<File>IOException - When a problem occurs while reading or obtaining
the image.public File getSource()
getSource in interface ImageSource<File>File representation of the source file.public String getInputFormatName()
ImageSource
getInputFormatName in interface ImageSource<File>null will be returned.public void setThumbnailParameter(ThumbnailParameter param)
ImageSourceThumbnailParameter from which to retrieve parameters
to use when retrieving the image.
setThumbnailParameter in interface ImageSource<File>param - The ThumbnailParameter with image
reading parameters.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||