#include <makernote.hpp>
Inheritance diagram for Exiv2::IfdMakerNote:
Public Types | |
typedef std::auto_ptr< IfdMakerNote > | AutoPtr |
Shortcut for an IfdMakerNote auto pointer. | |
Public Member Functions | |
Creators | |
IfdMakerNote (IfdId ifdId, bool alloc=true, bool hasNext=true) | |
Constructor. Requires an Ifd id and allows to choose whether or not memory management is needed for the Entries and whether the IFD has a next pointer. | |
IfdMakerNote (const IfdMakerNote &rhs) | |
Copy constructor. | |
virtual | ~IfdMakerNote () |
Virtual destructor. | |
Manipulators | |
virtual int | read (const byte *buf, long len, ByteOrder byteOrder, long offset) |
Read the makernote, including the makernote header, from character buffer buf of length len at position offset (from the start of the TIFF header) and encoded in byte order byteOrder. Return 0 if successful. | |
virtual int | readHeader (const byte *buf, long len, ByteOrder byteOrder) |
Read the makernote header from the makernote databuffer. This method must set the offset adjustment (adjOffset_), if needed (assuming that the required information is in the header). Return 0 if successful. | |
virtual long | copy (byte *buf, ByteOrder byteOrder, long offset) |
Copy (write) the makerNote to the character buffer buf at position offset (from the start of the TIFF header), encoded in byte order byteOrder. Update internal offsets if necessary. Return the number of bytes written. | |
virtual void | add (const Entry &entry) |
Add the entry to the makernote. No duplicate-check is performed, i.e., it is possible to add multiple entries with the same tag. The memory allocation mode of the entry to be added must be the same as that of the makernote and the IFD id of the entry must be set to 'makerIfd'. | |
virtual Entries::iterator | begin () |
The first makernote entry. | |
virtual Entries::iterator | end () |
End of the makernote entries. | |
virtual void | updateBase (byte *pNewBase) |
Update the base pointer of the MakerNote and all its entries to pNewBase. | |
Accessors | |
virtual Entries::const_iterator | begin () const |
The first makernote entry. | |
virtual Entries::const_iterator | end () const |
End of the makernote entries. | |
virtual Entries::const_iterator | findIdx (int idx) const |
Find an entry by idx, return a const iterator to the record. | |
virtual long | size () const |
Return the size of the makernote in bytes. | |
AutoPtr | create (bool alloc=true) const |
Return an auto-pointer to an newly created, empty instance of the same type as this. The makernote entries are not copied. The caller owns the new object and the auto-pointer ensures that it will be deleted. | |
AutoPtr | clone () const |
Return an auto-pointer to a clone of this object. The caller owns the new object and the auto-pointer ensures that it will be deleted. | |
virtual int | checkHeader () const |
Check the makernote header. This will typically check if a required prefix string is present in the header. Return 0 if successful. | |
virtual long | copyHeader (byte *buf) const |
Write the makernote header to a character buffer, return the number of characters written. | |
virtual long | headerSize () const |
Return the size of the makernote header in bytes. | |
Protected Attributes | |
bool | absOffset_ |
True: Adjustment of the IFD offsets is to be added to the offset from the start of the TIFF header (i.e., the start of the Exif data section), False: Adjustment of the IFD offsets is a suitable absolute value. Ignore the offset from the start of the TIFF header. | |
long | adjOffset_ |
Adjustment of the IFD offsets relative to the start of the TIFF header or to the start of the makernote, depending on the setting of absOffset_. | |
DataBuf | header_ |
Data buffer for the makernote header. | |
Ifd | ifd_ |
The makernote IFD. |
|
Check the makernote header. This will typically check if a required prefix string is present in the header. Return 0 if successful.
Reimplemented in Exiv2::FujiMakerNote, Exiv2::Nikon2MakerNote, Exiv2::Nikon3MakerNote, Exiv2::OlympusMakerNote, Exiv2::PanasonicMakerNote, Exiv2::SigmaMakerNote, and Exiv2::SonyMakerNote. |
|
Return an auto-pointer to a clone of this object. The caller owns the new object and the auto-pointer ensures that it will be deleted.
Reimplemented from Exiv2::MakerNote. Reimplemented in Exiv2::CanonMakerNote, Exiv2::FujiMakerNote, Exiv2::Nikon1MakerNote, Exiv2::Nikon2MakerNote, Exiv2::Nikon3MakerNote, Exiv2::OlympusMakerNote, Exiv2::PanasonicMakerNote, Exiv2::SigmaMakerNote, and Exiv2::SonyMakerNote. |
|
Write the makernote header to a character buffer, return the number of characters written.
|
|
Return an auto-pointer to an newly created, empty instance of the same type as this. The makernote entries are not copied. The caller owns the new object and the auto-pointer ensures that it will be deleted.
Reimplemented from Exiv2::MakerNote. Reimplemented in Exiv2::CanonMakerNote, Exiv2::FujiMakerNote, Exiv2::Nikon1MakerNote, Exiv2::Nikon2MakerNote, Exiv2::Nikon3MakerNote, Exiv2::OlympusMakerNote, Exiv2::PanasonicMakerNote, Exiv2::SigmaMakerNote, and Exiv2::SonyMakerNote. |
|
Return the size of the makernote header in bytes.
|
|
Read the makernote header from the makernote databuffer. This method must set the offset adjustment (adjOffset_), if needed (assuming that the required information is in the header). Return 0 if successful.
Reimplemented in Exiv2::FujiMakerNote, Exiv2::Nikon2MakerNote, Exiv2::Nikon3MakerNote, Exiv2::OlympusMakerNote, Exiv2::PanasonicMakerNote, Exiv2::SigmaMakerNote, and Exiv2::SonyMakerNote. |
|
Update the base pointer of the MakerNote and all its entries to pNewBase. Allows to re-locate the underlying data buffer to a new location pNewBase. This method only has an effect in non-alloc mode. Implements Exiv2::MakerNote. Reimplemented in Exiv2::CanonMakerNote. |