Class ComparisonPlan
Object
ComparisonPlan
A plan on which comparisons to execute for a test.
- Author:
- Owen Feehan
-
Constructor Summary
ConstructorsConstructorDescriptionComparisonPlan
(boolean bytewiseCompare, Optional<ImageFileFormat> formatVoxelwiseCompare, boolean skipComparisonForRGB) Creates a plan for particular settings.ComparisonPlan
(boolean bytewiseCompare, Optional<ImageFileFormat> formatVoxelwiseCompare, boolean skipComparisonForRGB, String directoryPathToCopyMissingImagesTo) Creates a plan for particular settings - and which copies any missing images to a particular directory. -
Method Summary
Modifier and TypeMethodDescriptioncreateComparer
(Path directory, String extension) Creates theImageComparer
to use to compare between images loaded in a temporary-directory and saved-images.boolean
The file-format to use for the voxel-wise comparison (if it's activated).int
hashCode()
boolean
boolean
toString()
-
Constructor Details
-
ComparisonPlan
public ComparisonPlan(boolean bytewiseCompare, Optional<ImageFileFormat> formatVoxelwiseCompare, boolean skipComparisonForRGB) Creates a plan for particular settings.- Parameters:
bytewiseCompare
- iff true, a bytewise comparison occurs between the saved-file and the newly created file.formatVoxelwiseCompare
- iff defined, a voxel-wise comparison occurs with the saved-rasters from a different format.skipComparisonForRGB
- if true, comparisons are not applied to RGB images.
-
ComparisonPlan
public ComparisonPlan(boolean bytewiseCompare, Optional<ImageFileFormat> formatVoxelwiseCompare, boolean skipComparisonForRGB, String directoryPathToCopyMissingImagesTo) Creates a plan for particular settings - and which copies any missing images to a particular directory.This helps create resource directories of saved-images, if they are missing.
- Parameters:
bytewiseCompare
- iff true, a bytewise comparison occurs between the saved-file and the newly created file.formatVoxelwiseCompare
- iff defined, a voxel-wise comparison occurs with the saved-rasters from a different file-format.skipComparisonForRGB
- if true, comparisons are not applied to RGB images.directoryPathToCopyMissingImagesTo
- a path to a directory to copy images to if a test fails (which we assume is evidence the image is missing).
-
-
Method Details
-
createComparer
Creates theImageComparer
to use to compare between images loaded in a temporary-directory and saved-images.- Parameters:
directory
- the temporary-directory where an image is created to be comparedextension
- the file-extension used in the temporary-directory- Returns:
- a newly created comparer
-
isBytewiseCompare
public boolean isBytewiseCompare() -
getFormatVoxelwiseCompare
The file-format to use for the voxel-wise comparison (if it's activated). -
isSkipComparisonForRGB
public boolean isSkipComparisonForRGB() -
getDirectoryPathToCopyMissingImagesTo
-
equals
-
hashCode
public int hashCode() -
toString
-