Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
101 changes: 59 additions & 42 deletions src/main/java/com/thebuzzmedia/exiftool/ExifTool.java
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@
* written the 2nd most robust image metadata library I have come across: <a
* href="http://drewnoakes.com/drewnoakes.com/code/exif/">Metadata Extractor</a>
* that you might want to look at.
*
*
* @author Riyad Kalla (software@thebuzzmedia.com)
* @since 1.1
*/
Expand Down Expand Up @@ -359,15 +359,15 @@ public class ExifTool {
* The external call to ExifTool to confirm feature support is only ever
* done once per JVM session and stored in a <code>static final</code>
* {@link Map} that all instances of this class share.
*
*
* @param feature
* The feature to check support for in the underlying ExifTool
* install.
*
*
* @return <code>true</code> if support for the given {@link Feature} was
* confirmed to work with the currently installed ExifTool or
* <code>false</code> if it is not supported.
*
*
* @throws IllegalArgumentException
* if <code>feature</code> is <code>null</code>.
* @throws RuntimeException
Expand Down Expand Up @@ -711,44 +711,61 @@ public enum Format {
* @since 1.1
*/
public enum Tag {
ISO("ISO", Integer.class), APERTURE("ApertureValue", Double.class), WHITE_BALANCE(
"WhiteBalance", Integer.class), CONTRAST("Contrast",
Integer.class), SATURATION("Saturation", Integer.class), SHARPNESS(
"Sharpness", Integer.class), SHUTTER_SPEED("ShutterSpeedValue",
Double.class), DIGITAL_ZOOM_RATIO("DigitalZoomRatio",
Double.class), IMAGE_WIDTH("ImageWidth", Integer.class), IMAGE_HEIGHT(
"ImageHeight", Integer.class), X_RESOLUTION("XResolution",
Double.class), Y_RESOLUTION("YResolution", Double.class), FLASH(
"Flash", Integer.class), METERING_MODE("MeteringMode",
Integer.class), FOCAL_LENGTH("FocalLength", Double.class), FOCAL_LENGTH_35MM(
"FocalLengthIn35mmFormat", Integer.class), EXPOSURE_TIME(
"ExposureTime", Double.class), EXPOSURE_COMPENSATION(
"ExposureCompensation", Double.class), EXPOSURE_PROGRAM(
"ExposureProgram", Integer.class), ORIENTATION("Orientation",
Integer.class), COLOR_SPACE("ColorSpace", Integer.class), SENSING_METHOD(
"SensingMethod", Integer.class), SOFTWARE("Software",
String.class), MAKE("Make", String.class), MODEL("Model",
String.class), LENS_MAKE("LensMake", String.class), LENS_MODEL(
"LensModel", String.class), OWNER_NAME("OwnerName",
String.class), TITLE("XPTitle", String.class), AUTHOR(
"XPAuthor", String.class), SUBJECT("XPSubject", String.class), KEYWORDS(
"XPKeywords", String.class), COMMENT("XPComment", String.class), RATING(
"Rating", Integer.class), RATING_PERCENT("RatingPercent",
Integer.class), DATE_TIME_ORIGINAL("DateTimeOriginal",
String.class), CREATION_DATE("CreationDate", String.class), GPS_LATITUDE(
"GPSLatitude", Double.class), GPS_LATITUDE_REF(
"GPSLatitudeRef", String.class), GPS_LONGITUDE("GPSLongitude",
Double.class), GPS_LONGITUDE_REF("GPSLongitudeRef",
String.class), GPS_ALTITUDE("GPSAltitude", Double.class), GPS_ALTITUDE_REF(
"GPSAltitudeRef", Integer.class), GPS_SPEED("GPSSpeed",
Double.class), GPS_SPEED_REF("GPSSpeedRef", String.class), GPS_PROCESS_METHOD(
"GPSProcessingMethod", String.class), GPS_BEARING(
"GPSDestBearing", Double.class), GPS_BEARING_REF(
"GPSDestBearingRef", String.class), GPS_TIMESTAMP(
"GPSTimeStamp", String.class), ROTATION("Rotation",Integer.class),
EXIF_VERSION("ExifVersion",String.class), LENS_ID("LensID",String.class);

private static final Map<String, Tag> TAG_LOOKUP_MAP;
APERTURE("ApertureValue", Double.class),
AUTHOR("XPAuthor", String.class),
COLOR_SPACE("ColorSpace", Integer.class),
COMMENT("XPComment", String.class),
CONTRAST("Contrast", Integer.class),
CREATION_DATE("CreationDate", String.class),
DATE_TIME_ORIGINAL("DateTimeOriginal", String.class),
DIGITAL_ZOOM_RATIO("DigitalZoomRatio", Double.class),
EXIF_VERSION("ExifVersion", String.class),
EXPOSURE_COMPENSATION("ExposureCompensation", Double.class),
EXPOSURE_PROGRAM("ExposureProgram", Integer.class),
EXPOSURE_TIME("ExposureTime", Double.class),
FLASH("Flash", Integer.class),
FOCAL_LENGTH("FocalLength", Double.class),
FOCAL_LENGTH_35MM("FocalLengthIn35mmFormat", Integer.class),
GPS_ALTITUDE("GPSAltitude", Double.class),
GPS_ALTITUDE_REF("GPSAltitudeRef", Integer.class),
GPS_BEARING("GPSDestBearing", Double.class),
GPS_BEARING_REF("GPSDestBearingRef", String.class),
GPS_LATITUDE("GPSLatitude", Double.class),
GPS_LATITUDE_REF("GPSLatitudeRef", String.class),
GPS_LONGITUDE("GPSLongitude", Double.class),
GPS_LONGITUDE_REF("GPSLongitudeRef", String.class),
GPS_PROCESS_METHOD("GPSProcessingMethod", String.class),
GPS_SPEED("GPSSpeed", Double.class),
GPS_SPEED_REF("GPSSpeedRef", String.class),
GPS_TIMESTAMP("GPSTimeStamp", String.class),
IMAGE_HEIGHT("ImageHeight", Integer.class),
IMAGE_WIDTH("ImageWidth", Integer.class),
ISO("ISO", Integer.class),
KEYWORDS("XPKeywords", String.class),
LENS_ID("LensID", String.class),
LENS_MAKE("LensMake", String.class),
LENS_MODEL("LensModel", String.class),
MAKE("Make", String.class),
METERING_MODE("MeteringMode", Integer.class),
MODEL("Model", String.class),
ORIENTATION("Orientation", Integer.class),
OWNER_NAME("OwnerName", String.class),
RATING("Rating", Integer.class),
RATING_PERCENT("RatingPercent", Integer.class),
ROTATION("Rotation", Integer.class),
SATURATION("Saturation", Integer.class),
SENSING_METHOD("SensingMethod", Integer.class),
SHARPNESS("Sharpness", Integer.class),
SHUTTER_SPEED("ShutterSpeedValue", Double.class),
SOFTWARE("Software", String.class),
SUBJECT("XPSubject", String.class),
SUB_SEC_TIME_ORIGINAL("SubSecTimeOriginal", Integer.class),
TITLE("XPTitle", String.class),
WHITE_BALANCE("WhiteBalance", Integer.class),
X_RESOLUTION("XResolution", Double.class),
Y_RESOLUTION("YResolution", Double.class);

private static final Map<String, Tag> TAG_LOOKUP_MAP;

/**
* Initializer used to init the <code>static final</code> tag/name
Expand Down