Package com.flir.thermalsdk.image
Class ImageFactory
java.lang.Object
com.flir.thermalsdk.image.ImageFactory
A factory used to create thermal or visual images instances based on provided path or URI.
-
Method Summary
Modifier and TypeMethodDescriptionstatic ImageBasecreateImage(@org.jetbrains.annotations.NotNull byte[] data) Creates an instance of a class basing on the provided byte array.static ImageBasecreateImage(@NotNull InputStream stream) Creates an instance of a class basing on the providedInputStream.static ImageBasecreateImage(@NotNull String absolutePath) Creates an instance of a class basing on the provided path.
-
Method Details
-
createImage
Creates an instance of a class basing on the provided path.- Parameters:
absolutePath- an absolute path to the image which will be created- Returns:
- Returns a created instance of a subclass of
ImageBaserelevant for provided path. - Throws:
IOException- when unable to open file with the specified path
-
createImage
Creates an instance of a class basing on the providedInputStream.- Parameters:
stream- anInputStreamrepresenting the image which will be created- Returns:
- Returns a created instance of a subclass of
ImageBaserelevant for provided stream. - Throws:
IOException- when unable to create image from givenInputStream
-
createImage
public static ImageBase createImage(@NotNull @org.jetbrains.annotations.NotNull byte[] data) throws IOException Creates an instance of a class basing on the provided byte array.- Parameters:
data- a byte array representing the image which will be created- Returns:
- Returns a created instance of a subclass of
ImageBaserelevant for provided byte array. - Throws:
IOException- when unable to create image from givenInputStream
-