Exiv2
Classes | Namespaces | Macros | Typedefs | Functions
value.hpp File Reference

Value interface and concrete subclasses. More...

#include "exiv2lib_export.h"
#include "types.hpp"
#include <map>
#include <iomanip>
#include <memory>
#include <cstring>
#include <climits>

Go to the source code of this file.

Classes

class  Exiv2::Value
 Common interface for all types of values used with metadata. More...
 
class  Exiv2::DataValue
 Value for an undefined data type. More...
 
class  Exiv2::StringValueBase
 Abstract base class for a string based Value type. More...
 
class  Exiv2::StringValue
 Value for string type. More...
 
class  Exiv2::AsciiValue
 Value for an Ascii string type. More...
 
class  Exiv2::CommentValue
 Value for an Exif comment. More...
 
struct  Exiv2::CommentValue::CharsetTable
 Information pertaining to the defined character sets. More...
 
class  Exiv2::CommentValue::CharsetInfo
 Charset information lookup functions. Implemented as a static class. More...
 
class  Exiv2::XmpValue
 Base class for all Exiv2 values used to store XMP property values. More...
 
class  Exiv2::XmpTextValue
 Value type suitable for simple XMP properties and XMP nodes of complex types which are not parsed into specific values. More...
 
class  Exiv2::XmpArrayValue
 Value type for simple arrays. Each item in the array is a simple value, without qualifiers. The array may be an ordered (seq), unordered (bag) or alternative array (alt). The array items must not contain qualifiers. For language alternatives use LangAltValue. More...
 
struct  Exiv2::LangAltValueComparator
 LangAltValueComparator More...
 
class  Exiv2::LangAltValue
 Value type for XMP language alternative properties. More...
 
class  Exiv2::DateValue
 Value for simple ISO 8601 dates More...
 
struct  Exiv2::DateValue::Date
 Simple Date helper structure. More...
 
class  Exiv2::TimeValue
 Value for simple ISO 8601 times. More...
 
struct  Exiv2::TimeValue::Time
 Simple Time helper structure. More...
 
class  Exiv2::ValueType< T >
 Template for a Value of a basic type. This is used for unsigned and signed short, long and rationals. More...
 

Namespaces

 Exiv2
 Provides classes and functions to encode and decode Exif and Iptc data. The libexiv2 API consists of the objects of this namespace.
 

Macros

#define LARGE_INT   1000000
 

Typedefs

typedef ValueType< uint16_t > Exiv2::UShortValue
 Unsigned short value type.
 
typedef ValueType< uint32_t > Exiv2::ULongValue
 Unsigned long value type.
 
typedef ValueType< URational > Exiv2::URationalValue
 Unsigned rational value type.
 
typedef ValueType< int16_t > Exiv2::ShortValue
 Signed short value type.
 
typedef ValueType< int32_t > Exiv2::LongValue
 Signed long value type.
 
typedef ValueType< Rational > Exiv2::RationalValue
 Signed rational value type.
 
typedef ValueType< float > Exiv2::FloatValue
 Float value type.
 
typedef ValueType< double > Exiv2::DoubleValue
 Double value type.
 

Functions

std::ostream & Exiv2::operator<< (std::ostream &os, const Value &value)
 Output operator for Value types.
 
template<typename T >
TypeId Exiv2::getType ()
 Template to determine the TypeId for a type T.
 
template<>
TypeId Exiv2::getType< uint16_t > ()
 Specialization for an unsigned short.
 
template<>
TypeId Exiv2::getType< uint32_t > ()
 Specialization for an unsigned long.
 
template<>
TypeId Exiv2::getType< URational > ()
 Specialization for an unsigned rational.
 
template<>
TypeId Exiv2::getType< int16_t > ()
 Specialization for a signed short.
 
template<>
TypeId Exiv2::getType< int32_t > ()
 Specialization for a signed long.
 
template<>
TypeId Exiv2::getType< Rational > ()
 Specialization for a signed rational.
 
template<>
TypeId Exiv2::getType< float > ()
 Specialization for a float.
 
template<>
TypeId Exiv2::getType< double > ()
 Specialization for a double.
 
template<typename T >
Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<>
uint16_t Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<>
uint32_t Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<>
URational Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<>
int16_t Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<>
int32_t Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<>
Rational Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<>
float Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<>
double Exiv2::getValue (const byte *buf, ByteOrder byteOrder)
 Read a value of type T from the data buffer. More...
 
template<typename T >
long Exiv2::toData (byte *buf, T t, ByteOrder byteOrder)
 Convert a value of type T to data, write the data to the data buffer. More...
 
template<>
long Exiv2::toData (byte *buf, uint16_t t, ByteOrder byteOrder)
 Specialization to write an unsigned short to the data buffer. Return the number of bytes written.
 
template<>
long Exiv2::toData (byte *buf, uint32_t t, ByteOrder byteOrder)
 Specialization to write an unsigned long to the data buffer. Return the number of bytes written.
 
template<>
long Exiv2::toData (byte *buf, URational t, ByteOrder byteOrder)
 Specialization to write an unsigned rational to the data buffer. Return the number of bytes written.
 
template<>
long Exiv2::toData (byte *buf, int16_t t, ByteOrder byteOrder)
 Specialization to write a signed short to the data buffer. Return the number of bytes written.
 
template<>
long Exiv2::toData (byte *buf, int32_t t, ByteOrder byteOrder)
 Specialization to write a signed long to the data buffer. Return the number of bytes written.
 
template<>
long Exiv2::toData (byte *buf, Rational t, ByteOrder byteOrder)
 Specialization to write a signed rational to the data buffer. Return the number of bytes written.
 
template<>
long Exiv2::toData (byte *buf, float t, ByteOrder byteOrder)
 Specialization to write a float to the data buffer. Return the number of bytes written.
 
template<>
long Exiv2::toData (byte *buf, double t, ByteOrder byteOrder)
 Specialization to write a double to the data buffer. Return the number of bytes written.
 

Detailed Description

Value interface and concrete subclasses.

Author
Andreas Huggel (ahu) ahuggel@gmx.net
Date
09-Jan-04, ahu: created 11-Feb-04, ahu: isolated as a component 31-Jul-04, brad: added Time, Data and String values