31 #ifndef METADATUM_HPP_ 32 #define METADATUM_HPP_ 35 #include "exiv2lib_export.h" 76 virtual const char* familyName()
const =0;
84 virtual uint16_t tag()
const =0;
97 std::ostream&
write(std::ostream& os)
const {
return os << key(); }
107 Key& operator=(
const Key& rhs);
112 virtual Key* clone_()
const =0;
119 return key.
write(os);
195 virtual std::ostream& write(
207 virtual const char* familyName()
const =0;
215 virtual uint16_t tag()
const =0;
217 virtual TypeId typeId()
const =0;
219 virtual const char* typeName()
const =0;
221 virtual long typeSize()
const =0;
223 virtual long count()
const =0;
225 virtual long size()
const =0;
239 virtual long toLong(
long n =0)
const =0;
245 virtual float toFloat(
long n =0)
const =0;
251 virtual Rational toRational(
long n =0)
const =0;
279 virtual const Value& value()
const =0;
316 #endif // #ifndef METADATUM_HPP_ EXIV2API bool cmpMetadataByKey(const Metadatum &lhs, const Metadatum &rhs)
Compare two metadata by key. Return true if the key of metadatum lhs is less than that of rhs...
Definition: metadatum.cpp:84
EXIV2API bool cmpMetadataByTag(const Metadatum &lhs, const Metadatum &rhs)
Compare two metadata by tag. Return true if the tag of metadatum lhs is less than that of rhs...
Definition: metadatum.cpp:78
A container for Exif data. This is a top-level class of the Exiv2 library. The container holds Exifda...
Definition: exif.hpp:434
ByteOrder
Type to express the byte order (little or big endian)
Definition: types.hpp:113
std::pair< int32_t, int32_t > Rational
8 byte signed rational type.
Definition: types.hpp:110
T getValue(const byte *buf, ByteOrder byteOrder)
Read a value of type T from the data buffer.
Definition: value.hpp:1372
TypeId
Exiv2 value type identifiers.
Definition: types.hpp:130
Abstract base class defining the Key of a metadatum. Keys are used to identify and group metadata...
Definition: metadatum.hpp:55
uint8_t byte
1 byte unsigned integer type.
Definition: types.hpp:105
std::string toString(const T &arg)
Utility function to convert the argument of any type to a string.
Definition: types.hpp:521
Exiv2::Exifdatum & setValue(Exiv2::Exifdatum &exifDatum, const T &value)
Set the value of exifDatum to value. If the object already has a value, it is replaced. Otherwise a new ValueType<T> value is created and set to value.
Definition: exif.cpp:193
std::ostream & write(std::ostream &os) const
Write the key to an output stream. You do not usually have to use this function; it is used for the i...
Definition: metadatum.hpp:97
const char * groupName(IfdId ifdId)
Return the group name for a group id.
Definition: tags_int.cpp:2155
IPTC string type.
Definition: types.hpp:147
Common interface for all types of values used with metadata.
Definition: value.hpp:60
std::auto_ptr< Value > AutoPtr
Shortcut for a Value auto pointer.
Definition: value.hpp:63
Provides classes and functions to encode and decode Exif and Iptc data. The libexiv2 API consists of ...
Definition: asfvideo.hpp:36
EXIV2API std::ostream & operator<<(std::ostream &os, const DataSet &dataSet)
Output operator for dataSet.
Definition: datasets.cpp:709
std::auto_ptr< Key > AutoPtr
Shortcut for a Key auto pointer.
Definition: metadatum.hpp:58
Value interface and concrete subclasses.