#include <value.hpp>
Inheritance diagram for Exiv2::XmpTextValue:
Public Types | |
typedef std::auto_ptr< XmpTextValue > | AutoPtr |
Shortcut for a XmpTextValue auto pointer. | |
Public Member Functions | |
Creators | |
XmpTextValue () | |
Constructor. | |
XmpTextValue (const std::string &buf) | |
Constructor, reads the value from a string. | |
Manipulators | |
virtual int | read (const std::string &buf) |
Read a simple property value from buf to set the value. | |
virtual int | read (const byte *buf, long len, ByteOrder byteOrder=invalidByteOrder) |
Read the value from a character buffer. | |
virtual int | read (const std::string &buf)=0 |
Accessors | |
AutoPtr | clone () const |
Return an auto-pointer to a copy of itself (deep copy). The caller owns this copy and the auto-pointer ensures that it will be deleted. | |
long | size () const |
Return the size of the value in bytes. | |
virtual long | count () const |
Return the number of components of the value. | |
virtual long | toLong (long n=0) const |
Convert the value to a long. The optional parameter n is not used and is ignored. | |
virtual float | toFloat (long n=0) const |
Convert the value to a float. The optional parameter n is not used and is ignored. | |
virtual Rational | toRational (long n=0) const |
Convert the value to a Rational. The optional parameter n is not used and is ignored. | |
virtual std::ostream & | write (std::ostream &os) const |
Write the value to an output stream. You do not usually have to use this function; it is used for the implementation of the output operator for Value, operator<<(std::ostream &os, const Value &value). | |
Public Attributes | |
std::string | value_ |
Stores the string values. |
Uses a std::string to store the value.
|
Read the value from a character buffer. Uses read(const std::string& buf)
|
|
Read a simple property value from buf to set the value. Sets the value to the contents of buf. A optional keyword, type is supported to set the XMP value type. This is useful for complex value types for which Exiv2 does not have direct support.
The format of buf is:
Implements Exiv2::XmpValue. |
|
Convert the value to a float. The optional parameter n is not used and is ignored.
Implements Exiv2::Value. |
|
Convert the value to a long. The optional parameter n is not used and is ignored.
Implements Exiv2::Value. |
|
Convert the value to a Rational. The optional parameter n is not used and is ignored.
Implements Exiv2::Value. |