public class TagDescriptor<T extends Directory> extends Object
Modifier and Type | Field and Description |
---|---|
protected T |
_directory |
Constructor and Description |
---|
TagDescriptor(T directory) |
Modifier and Type | Method and Description |
---|---|
static String |
convertBytesToVersionString(int[] components,
int majorDigits)
Takes a series of 4 bytes from the specified offset, and converts these to a
well-known version number, where possible.
|
protected String |
get7BitStringFromBytes(int tagType) |
protected String |
getAsciiStringFromBytes(int tag) |
protected String |
getBitFlagDescription(int tagType,
Object... labels)
LSB first.
|
protected String |
getByteLengthDescription(int tagType) |
protected String |
getDecimalRational(int tagType,
int decimalPlaces) |
String |
getDescription(int tagType)
Returns a descriptive value of the specified tag for this image.
|
protected String |
getEpochTimeDescription(int tagType) |
protected String |
getFormattedFloat(int tagType,
String format) |
protected String |
getFormattedInt(int tagType,
String format) |
protected String |
getFormattedString(int tagType,
String format) |
protected String |
getIndexedDescription(int tagType,
int baseIndex,
String... descriptions) |
protected String |
getIndexedDescription(int tagType,
String... descriptions) |
protected String |
getSimpleRational(int tagType) |
protected String |
getVersionBytesDescription(int tagType,
int majorDigits) |
public TagDescriptor(T directory)
public String getDescription(int tagType)
getString(tagType)
will be returned.tagType
- the tag to find a description fornull
if the tag hasn't been defined.public static String convertBytesToVersionString(int[] components, int majorDigits)
Two different formats are processed:
components
- the four version valuesmajorDigits
- the number of components to beprotected String getVersionBytesDescription(int tagType, int majorDigits)
protected String getIndexedDescription(int tagType, int baseIndex, String... descriptions)
protected String getByteLengthDescription(int tagType)
protected String getSimpleRational(int tagType)
protected String getDecimalRational(int tagType, int decimalPlaces)
protected String getEpochTimeDescription(int tagType)
protected String getBitFlagDescription(int tagType, Object... labels)
protected String get7BitStringFromBytes(int tagType)
protected String getAsciiStringFromBytes(int tag)
Copyright © 2002-2015 Drew Noakes. All Rights Reserved.