Package com.luciad.format.raster
Class TLcdGeoTIFFField
java.lang.Object
com.luciad.format.raster.TLcdGeoTIFFField
This class describes a TIFF or GeoTIFF tag and the corresponding field.
The tag normally serves as a key. The field then contains a value or a list
of values that can be numeric or textual.
The data can be of the following types:
TIFF type | Data type |
---|---|
TYPE_ASCII | String[] |
TYPE_SBYTE | byte[] |
TYPE_BYTE | byte[] |
TYPE_SSHORT | short[] |
TYPE_SHORT | char[] |
TYPE_SLONG | int[] |
TYPE_LONG | long[] |
TYPE_FLOAT | float[] |
TYPE_DOUBLE | double[] |
TYPE_SRATIONAL | int[][] |
TYPE_RATIONAL | long[][] |
TYPE_UNDEFINED | byte[] |
- Since:
- 8.1.06
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
The ASCII type, with data represented as an array of Strings.static final int
The unsigned byte type (8 bits), with data represented as an array of shorts.static final int
The float type (64 bits IEEE), with data represented as an array of doubles.static final int
The float type (32 bits IEEE), with data represented as an array of floats.static final int
The type for a 32-bit pointer to an image file directory.static final int
The type for a 64-bit pointer to an image file directory.static final int
The unsigned long type (32 bits), with data represented as an array of longs.static final int
The unsigned rational type (2x32 bits), with data represented as an array containing arrays of two longs.static final int
The signed byte type (8 bits), with data represented as an array of bytes.static final int
The unsigned short type (16 bits), with data represented as an array of ints.static final int
The signed long type (32 bits), with data represented as an array of ints.static final int
The signed rational type (2x32 bits), with data represented as an array containing arrays of two ints.static final int
The signed short type (16 bits), with data represented as an array of shorts.static final int
The undefined type, with data represented as an array of bytes. -
Constructor Summary
ConstructorDescriptionTLcdGeoTIFFField
(int aTag, int aType, int aCount, Object aData) Creates a new TLcdGeoTIFFField containing the specified tag and values. -
Method Summary
Modifier and TypeMethodDescriptionint
getCount()
Returns the number of data values of this field.getData()
Returns the data (value or values) contained in this field.Returns the (first) numeric value, if this field has a numeric type.getNumericValue
(int aIndex) Returns the numeric value at the specified index, if this field has a numeric type.Returns the (first) string value, if this field has an ASCII type.getStringValue
(int aIndex) Returns the string value at the specified index, if this field has an ASCII type.int
getTag()
Returns the tag (key) of this field.int
getType()
Returns the type of the data of this field.toString()
-
Field Details
-
TYPE_ASCII
public static final int TYPE_ASCIIThe ASCII type, with data represented as an array of Strings.- See Also:
-
TYPE_SBYTE
public static final int TYPE_SBYTEThe signed byte type (8 bits), with data represented as an array of bytes.- See Also:
-
TYPE_BYTE
public static final int TYPE_BYTEThe unsigned byte type (8 bits), with data represented as an array of shorts.- See Also:
-
TYPE_SSHORT
public static final int TYPE_SSHORTThe signed short type (16 bits), with data represented as an array of shorts.- See Also:
-
TYPE_SHORT
public static final int TYPE_SHORTThe unsigned short type (16 bits), with data represented as an array of ints.- See Also:
-
TYPE_SLONG
public static final int TYPE_SLONGThe signed long type (32 bits), with data represented as an array of ints.- See Also:
-
TYPE_LONG
public static final int TYPE_LONGThe unsigned long type (32 bits), with data represented as an array of longs.- See Also:
-
TYPE_FLOAT
public static final int TYPE_FLOATThe float type (32 bits IEEE), with data represented as an array of floats.- See Also:
-
TYPE_DOUBLE
public static final int TYPE_DOUBLEThe float type (64 bits IEEE), with data represented as an array of doubles.- See Also:
-
TYPE_SRATIONAL
public static final int TYPE_SRATIONALThe signed rational type (2x32 bits), with data represented as an array containing arrays of two ints.- See Also:
-
TYPE_RATIONAL
public static final int TYPE_RATIONALThe unsigned rational type (2x32 bits), with data represented as an array containing arrays of two longs.- See Also:
-
TYPE_UNDEFINED
public static final int TYPE_UNDEFINEDThe undefined type, with data represented as an array of bytes.- See Also:
-
TYPE_IFD_POINTER
public static final int TYPE_IFD_POINTERThe type for a 32-bit pointer to an image file directory.- See Also:
-
TYPE_IFD8_POINTER
public static final int TYPE_IFD8_POINTERThe type for a 64-bit pointer to an image file directory.- See Also:
-
-
Constructor Details
-
TLcdGeoTIFFField
Creates a new TLcdGeoTIFFField containing the specified tag and values.- Parameters:
aTag
- the TIFF tagaType
- one ofTYPE_ASCII
,TYPE_SBYTE
, etc.aCount
- the number of data values.aData
- the TIFF data, presented as an array of the proper data type.
-
-
Method Details
-
getTag
public int getTag()Returns the tag (key) of this field. -
getType
public int getType()Returns the type of the data of this field.- Returns:
- one of
TYPE_ASCII
,TYPE_SBYTE
, etc.
-
getCount
public int getCount()Returns the number of data values of this field.- Returns:
- the number of data values.
-
getData
Returns the data (value or values) contained in this field.- Returns:
- an array of the type that is determined by the type property.
-
getNumericValue
Returns the (first) numeric value, if this field has a numeric type.- Returns:
- the numeric value.
-
getNumericValue
Returns the numeric value at the specified index, if this field has a numeric type.- Parameters:
aIndex
- the index of the numeric value.- Returns:
- the numeric value.
-
getStringValue
Returns the (first) string value, if this field has an ASCII type.- Returns:
- the string value.
-
getStringValue
Returns the string value at the specified index, if this field has an ASCII type.- Parameters:
aIndex
- the index of the string value.- Returns:
- the string value.
-
toString
-