Exiv2
|
Utility class provides the block mapping to the part of data. This avoids allocating a single contiguous block of memory to the big data. More...
#include <basicio.hpp>
Public Types | |
enum | blockType_e { bNone, bKnown, bMemory } |
the status of the block. | |
Public Member Functions | |
Creators | |
BlockMap () | |
Default constructor. the init status of the block is bNone. | |
virtual | ~BlockMap () |
Destructor. Releases all managed memory. | |
Manipulators | |
void | populate (byte *source, size_t num) |
Populate the block. More... | |
void | markKnown (size_t num) |
Change the status to bKnow. bKnow blocks do not contain the data, but they keep the size of data. This avoids allocating memory for parts of the file that contain image-date (non-metadata/pixel data) which never change in exiv2. More... | |
Accessors | |
bool | isNone () |
bool | isInMem () |
bool | isKnown () |
byte * | getData () |
size_t | getSize () |
Utility class provides the block mapping to the part of data. This avoids allocating a single contiguous block of memory to the big data.
|
inline |
Change the status to bKnow. bKnow blocks do not contain the data, but they keep the size of data. This avoids allocating memory for parts of the file that contain image-date (non-metadata/pixel data) which never change in exiv2.
num | The size of the data |
Referenced by Exiv2::RemoteIo::populateFakeData().
|
inline |
Populate the block.
source | The data populate to the block |
num | The size of data |
Referenced by Exiv2::RemoteIo::open().