Package com.drew.metadata
Class Tag
- java.lang.Object
-
- com.drew.metadata.Tag
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetDescription()Get a description of the tag's value, considering enumerated values and units.StringgetDirectoryName()StringgetTagName()Get the name of the tag, such asAperture, orInteropVersion.intgetTagType()Gets the tag type as an intStringgetTagTypeHex()Gets the tag type in hex notation as a String with padded leading zeroes if necessary (i.e.booleanhasTagName()Get whether this tag has a name.StringtoString()A basic representation of the tag's type and value.
-
-
-
Constructor Detail
-
Tag
public Tag(int tagType, Directory directory)
-
-
Method Detail
-
getTagType
public int getTagType()
Gets the tag type as an int- Returns:
- the tag type as an int
-
getTagTypeHex
public String getTagTypeHex()
Gets the tag type in hex notation as a String with padded leading zeroes if necessary (i.e.0x100e).- Returns:
- the tag type as a string in hexadecimal notation
-
getDescription
public String getDescription()
Get a description of the tag's value, considering enumerated values and units.- Returns:
- a description of the tag's value
-
hasTagName
public boolean hasTagName()
Get whether this tag has a name. Iftrue, it may be accessed viagetTagName(). Iffalse,getTagName()will return a string resembling"Unknown tag (0x1234)".- Returns:
- whether this tag has a name
-
getTagName
public String getTagName()
Get the name of the tag, such asAperture, orInteropVersion.- Returns:
- the tag's name
-
getDirectoryName
public String getDirectoryName()
- Returns:
- name of the
Directoryin which this tag exists
-
-