How to distinguish the type of value of the metadata tag

Started by kingvhit, December 10, 2019, 02:38:21 AM

Previous topic - Next topic

kingvhit

Hi, first of all, thank you very much for your best library Phil Harvey.

I have made a portable application on Android, the UI look like bellow


As you see, almost the value of the attribute is responded as String format, so difficult to parse, verify or check them and display what the input type must be shown to easy edit for the user.
Like, if tap to ApectureValue, it must be display popup with input and only accept the double value input.
Or if tap to CreateDAte it must be displayed a popup with Date Time Picker
Or tap to Map it must show the map picker.
... many other cases.

So, I have export all the data type of the tags, and I can also get the Table Name, type of that attribute like int32u, int16u, rational64u, ...

Does has anyway that I can identify its to the type of Java/C code like if its attribute is ApectureValue I can cast to Double. something like that.

One more time, thank you for your help.
Regards

Phil Harvey

The format for the tags is given in the -listx output.  However, this is the storage format, not the input format/output format.  ExifTool can sometimes be very flexible about the input format, and often translates numbers to human-readable descriptions, so if you try to restrict this you may be limiting the capabilities of ExifTool.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

kingvhit

Hi, thank you for your reply. I have to make own database by myself. Many tags must convert. Thank you 8)