public abstract class TiffProfile extends Object
getText
when satisfiesProfile
returns true.Modifier and Type | Field and Description |
---|---|
protected int |
_mimeClass |
protected String |
_profileText
PRIVATE CLASS FIELDS.
|
static int |
MIME_1314
Values for mimeClass.
|
static int |
MIME_FX
Values for mimeClass.
|
static int |
MIME_GENERIC
Values for mimeClass.
|
Constructor and Description |
---|
TiffProfile()
Creates a TiffProfile.
|
Modifier and Type | Method and Description |
---|---|
int |
getMimeClass()
Returns the MIME class for this profile.
|
String |
getText()
Returns the text which describes this profile.
|
boolean |
isAlreadyOK()
Returns the value of the alreadyOK flag.
|
protected boolean |
satisfiesBackgroundColorIndicator(TiffIFD ifd,
int value)
Checks if the value of the BackgroundColorIndicator tag matches
the value passed to it.
|
protected boolean |
satisfiesBackgroundColorIndicator(TiffIFD ifd,
int[] values)
Checks if the value of the BackgroundColorIndicator tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesCompression(TiffIFD ifd,
int value)
Checks if the value of the PlanarConfiguration tag matches
the value passed to it.
|
protected boolean |
satisfiesCompression(TiffIFD ifd,
int[] values)
Checks if the value of the Compression tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesDotRange(TiffIFD ifd,
int minValue,
int maxValue)
Checks the DotRange against a minimum and a maximum value.
|
protected boolean |
satisfiesFillOrder(TiffIFD ifd,
int[] values)
Checks if the value of the Indexed tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesImageColorIndicator(TiffIFD ifd,
int value)
Checks if the value of the ImageColorIndicator tag matches
the value passed to it.
|
protected boolean |
satisfiesImageColorIndicator(TiffIFD ifd,
int[] values)
Checks if the value of the ImageColorIndicator tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesImageWidth(TiffIFD ifd,
int[] values)
Checks if the value of the ImageWidth tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesIndexed(TiffIFD ifd,
int[] values)
Checks if the value of the Indexed tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesNewSubfileType(TiffIFD ifd,
long value)
Checks if the value of the NewSubfileType tag matches
the value passed to it.
|
protected boolean |
satisfiesNewSubfileType(TiffIFD ifd,
long[] values)
Checks if the value of the NewSubfileType tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesOrientation(TiffIFD ifd,
int value)
Checks if the value of the Orientation tag matches
the value passed to it.
|
protected boolean |
satisfiesOrientation(TiffIFD ifd,
int[] values)
Checks if the value of the Orientation tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesPhotometricInterpretation(TiffIFD ifd,
int value)
Checks if the value of the PhotometricInterpretation tag matches
the value passed to it.
|
protected boolean |
satisfiesPhotometricInterpretation(TiffIFD ifd,
int[] values)
Checks if the value of the PhotometricInterpretation tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesPlanarConfiguration(TiffIFD ifd,
int value)
Checks if the value of the PlanarConfiguration tag matches
the value passed to it.
|
protected boolean |
satisfiesPlanarConfiguration(TiffIFD ifd,
int[] values)
Checks if the value of the PlanarConfiguration tag matches
any of the values in the array passed to it.
|
boolean |
satisfiesProfile(IFD ifd)
Returns
true if the IFD satisfies the profile. |
protected boolean |
satisfiesResolutionUnit(TiffIFD ifd,
int value)
Checks if the value of the ResolutionUnit tag matches
the value passed to it.
|
protected boolean |
satisfiesResolutionUnit(TiffIFD ifd,
int[] values)
Checks if the value of the ResolutionUnit tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesSamplesPerPixel(TiffIFD ifd,
int value)
Checks if the value of the SamplesPerPixel tag matches
the value passed to it.
|
protected boolean |
satisfiesSamplesPerPixel(TiffIFD ifd,
int[] values)
Checks if the value of the SamplesPerPixel tag matches
any of the values in the array passed to it.
|
abstract boolean |
satisfiesThisProfile(IFD ifd)
Returns
true if the IFD satisfies the
profile. |
protected boolean |
satisfiesXResolution(TiffIFD ifd,
int[] values)
Checks if the value of the XResolution tag matches
any of the values in the array passed to it.
|
protected boolean |
satisfiesYResolution(TiffIFD ifd,
int[] values)
Checks if the value of the XResolution tag matches
any of the values in the array passed to it.
|
void |
setAlreadyOK(boolean ok)
Sets the value of the alreadyOK flag.
|
protected String _profileText
protected int _mimeClass
public static final int MIME_GENERIC
public static final int MIME_FX
public static final int MIME_1314
public TiffProfile()
public final boolean satisfiesProfile(IFD ifd)
true
if the IFD satisfies the profile.
This calls satisfiesThisProfile()
, which does the actual work.
satisfiesProfile()
sets the alreadyOK flag, which may be
checked by calling isAlreadyOK()
to save the effort of
testing the same profile more than once and thus generating
duplicate output.
Subclasses should not override satisfiesProfile
.ifd
- The IFD which is being evaluated against the profilepublic abstract boolean satisfiesThisProfile(IFD ifd)
true
if the IFD satisfies the
profile. Subclasses should override satisfiesThisProfile()
,
not satisfiesProfile()
, as
satisfiesProfile()
does some
additional bookkeeping for all subclases.public String getText()
public void setAlreadyOK(boolean ok)
public int getMimeClass()
public boolean isAlreadyOK()
true
.protected boolean satisfiesCompression(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesCompression(TiffIFD ifd, int value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesPhotometricInterpretation(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesPhotometricInterpretation(TiffIFD ifd, int value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesResolutionUnit(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesResolutionUnit(TiffIFD ifd, int value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesXResolution(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesYResolution(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesSamplesPerPixel(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesSamplesPerPixel(TiffIFD ifd, int value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesPlanarConfiguration(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesPlanarConfiguration(TiffIFD ifd, int value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesOrientation(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesOrientation(TiffIFD ifd, int value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesImageColorIndicator(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesImageColorIndicator(TiffIFD ifd, int value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesNewSubfileType(TiffIFD ifd, long[] values)
ifd
- The IFD being checkedvalues
- An array of long values, any of which will
satisfy the test.protected boolean satisfiesNewSubfileType(TiffIFD ifd, long value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesBackgroundColorIndicator(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesBackgroundColorIndicator(TiffIFD ifd, int value)
ifd
- The IFD being checkedvalue
- A value which must match the tag value to
satisfy the test.protected boolean satisfiesDotRange(TiffIFD ifd, int minValue, int maxValue)
protected boolean satisfiesImageWidth(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesIndexed(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.protected boolean satisfiesFillOrder(TiffIFD ifd, int[] values)
ifd
- The IFD being checkedvalues
- An array of values, any of which will
satisfy the test.Copyright © 2008–2017 The Open Preservation Foundation. All rights reserved.