Sophie

Sophie

distrib > Mandriva > 2008.1 > x86_64 > media > main-release > by-pkgid > e31b59fe09ff595814e8029d984f51c5 > files > 351

lib64exiv2_2-devel-0.16-3mdv2008.1.x86_64.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>Exiv2: Exiv2::Ifd Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.4 -->
<div class="tabs">
  <ul>
    <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
    <li><a href="namespaces.html"><span>Namespaces</span></a></li>
    <li class="current"><a href="classes.html"><span>Classes</span></a></li>
    <li><a href="files.html"><span>Files</span></a></li>
    <li><a href="examples.html"><span>Examples</span></a></li>
    <li>
      <form action="search.php" method="get">
        <table cellspacing="0" cellpadding="0" border="0">
          <tr>
            <td><label>&nbsp;<u>S</u>earch&nbsp;for&nbsp;</label></td>
            <td><input type="text" name="query" value="" size="20" accesskey="s"/></td>
          </tr>
        </table>
      </form>
    </li>
  </ul>
</div>
<div class="tabs">
  <ul>
    <li><a href="classes.html"><span>Alphabetical&nbsp;List</span></a></li>
    <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
    <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
    <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
  </ul>
</div>
<div class="nav">
<a class="el" href="namespaceExiv2.html">Exiv2</a>::<a class="el" href="classExiv2_1_1Ifd.html">Ifd</a></div>
<h1>Exiv2::Ifd Class Reference</h1><!-- doxytag: class="Exiv2::Ifd" -->Models an IFD (Image File Directory).  
<a href="#_details">More...</a>
<p>
<code>#include &lt;ifd.hpp&gt;</code>
<p>
<div class="dynheader">
Collaboration diagram for Exiv2::Ifd:</div>
<div class="dynsection">
<p><center><img src="classExiv2_1_1Ifd__coll__graph.png" border="0" usemap="#Exiv2_1_1Ifd__coll__map" alt="Collaboration graph"></center>
<map name="Exiv2_1_1Ifd__coll__map">
<area shape="rect" title="STL class." alt="" coords="5,6,187,30"></map>
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center></div>

<p>
<a href="classExiv2_1_1Ifd-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Types</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="e1a940634eeaaf03e3635b666ee8ab06"></a><!-- doxytag: member="Exiv2::Ifd::const_iterator" ref="e1a940634eeaaf03e3635b666ee8ab06" args="" -->
typedef Entries::const_iterator&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#e1a940634eeaaf03e3635b666ee8ab06">const_iterator</a></td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Entries const iterator type <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="9c93a8ce8a9645aa66c152641a91fb56"></a><!-- doxytag: member="Exiv2::Ifd::iterator" ref="9c93a8ce8a9645aa66c152641a91fb56" args="" -->
typedef Entries::iterator&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#9c93a8ce8a9645aa66c152641a91fb56">iterator</a></td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Entries iterator type <br></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td colspan="2"><div class="groupHeader">Creators</div></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="35ca0bcd5456f652da470abc6796252b"></a><!-- doxytag: member="Exiv2::Ifd::Ifd" ref="35ca0bcd5456f652da470abc6796252b" args="(IfdId ifdId=ifdIdNotSet)" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#35ca0bcd5456f652da470abc6796252b">Ifd</a> (<a class="el" href="namespaceExiv2.html#1615152767a506a955c9d13443b56b62">IfdId</a> ifdId=ifdIdNotSet)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor. Allows to set the IFD identifier. Memory management is enabled, offset is set to 0. Serves as default constructor. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="4152ff215d6ef0af0f25a4399f47e766"></a><!-- doxytag: member="Exiv2::Ifd::Ifd" ref="4152ff215d6ef0af0f25a4399f47e766" args="(IfdId ifdId, long offset)" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#4152ff215d6ef0af0f25a4399f47e766">Ifd</a> (<a class="el" href="namespaceExiv2.html#1615152767a506a955c9d13443b56b62">IfdId</a> ifdId, long offset)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor. Allows to set the IFD identifier and the offset of the IFD from the start of TIFF header. Memory management is enabled. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="c2742ff3480abd123bec2a169bb9ab6a"></a><!-- doxytag: member="Exiv2::Ifd::Ifd" ref="c2742ff3480abd123bec2a169bb9ab6a" args="(IfdId ifdId, long offset, bool alloc, bool hasNext=true)" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#c2742ff3480abd123bec2a169bb9ab6a">Ifd</a> (<a class="el" href="namespaceExiv2.html#1615152767a506a955c9d13443b56b62">IfdId</a> ifdId, long offset, bool alloc, bool hasNext=true)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor. Allows to set the IFD identifier, offset of the IFD from the start of TIFF header, choose whether or not memory management is required for the Entries, and decide whether this IFD has a next pointer. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="868c86a9a804070023bfb81836d0a358"></a><!-- doxytag: member="Exiv2::Ifd::Ifd" ref="868c86a9a804070023bfb81836d0a358" args="(const Ifd &amp;rhs)" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#868c86a9a804070023bfb81836d0a358">Ifd</a> (const <a class="el" href="classExiv2_1_1Ifd.html">Ifd</a> &amp;rhs)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Copy constructor. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="42a28a311e121156bf024e5554d30519"></a><!-- doxytag: member="Exiv2::Ifd::~Ifd" ref="42a28a311e121156bf024e5554d30519" args="()" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#42a28a311e121156bf024e5554d30519">~Ifd</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Destructor. <br></td></tr>
<tr><td colspan="2"><div class="groupHeader">Manipulators</div></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#8d86b9dfa71fb413978822ed388d5f78">read</a> (const <a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *buf, long len, long start, <a class="el" href="namespaceExiv2.html#94c225faf6d6c611a3828fae1c28efa6">ByteOrder</a> byteOrder, long shift=0)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a complete IFD and its data from a data buffer.  <a href="#8d86b9dfa71fb413978822ed388d5f78"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#e4111e2b5234b5dab141e4fd7194eabd">copy</a> (<a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *buf, <a class="el" href="namespaceExiv2.html#94c225faf6d6c611a3828fae1c28efa6">ByteOrder</a> byteOrder, long offset=0)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Copy the IFD to a data array, update the offsets of the IFD and all its entries, return the number of bytes written.  <a href="#e4111e2b5234b5dab141e4fd7194eabd"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="559627e0f77d37556a73c6e808b7a7fb"></a><!-- doxytag: member="Exiv2::Ifd::clear" ref="559627e0f77d37556a73c6e808b7a7fb" args="()" -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#559627e0f77d37556a73c6e808b7a7fb">clear</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Reset the IFD. Delete all IFD entries from the class and put the object in a state where it can accept completely new entries. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="2b8878af1f47c9acc083141ee349c41a"></a><!-- doxytag: member="Exiv2::Ifd::setNext" ref="2b8878af1f47c9acc083141ee349c41a" args="(uint32_t next, ByteOrder byteOrder)" -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#2b8878af1f47c9acc083141ee349c41a">setNext</a> (uint32_t next, <a class="el" href="namespaceExiv2.html#94c225faf6d6c611a3828fae1c28efa6">ByteOrder</a> byteOrder)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the offset of the next IFD. Byte order is needed to update the underlying data buffer in non-alloc mode. This method only has an effect if the IFD was instantiated with hasNext = true. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="f3c1d754bc8082eec986a91be12f8cb0"></a><!-- doxytag: member="Exiv2::Ifd::add" ref="f3c1d754bc8082eec986a91be12f8cb0" args="(const Entry &amp;entry)" -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#f3c1d754bc8082eec986a91be12f8cb0">add</a> (const <a class="el" href="classExiv2_1_1Entry.html">Entry</a> &amp;entry)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Add the entry to the IFD. 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 match that of the IFD and the IFD ids of the IFD and entry must match. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="f1389f168b084badf2cd73c380d28ea3"></a><!-- doxytag: member="Exiv2::Ifd::erase" ref="f1389f168b084badf2cd73c380d28ea3" args="(uint16_t tag)" -->
int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#f1389f168b084badf2cd73c380d28ea3">erase</a> (uint16_t tag)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Delete the directory entry with the given tag. Return the index of the deleted entry or 0 if no entry with tag was found. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="368820f1aaf6baf20a0d87b9c4fe0703"></a><!-- doxytag: member="Exiv2::Ifd::erase" ref="368820f1aaf6baf20a0d87b9c4fe0703" args="(iterator pos)" -->
<a class="el" href="classExiv2_1_1Ifd.html#9c93a8ce8a9645aa66c152641a91fb56">iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#368820f1aaf6baf20a0d87b9c4fe0703">erase</a> (<a class="el" href="classExiv2_1_1Ifd.html#9c93a8ce8a9645aa66c152641a91fb56">iterator</a> pos)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Delete the directory entry at iterator position pos, return the position of the next entry. Note that iterators into the directory, including pos, are potentially invalidated by this call. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="c98ad7d2422810a0a253d86452a46bae"></a><!-- doxytag: member="Exiv2::Ifd::sortByTag" ref="c98ad7d2422810a0a253d86452a46bae" args="()" -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#c98ad7d2422810a0a253d86452a46bae">sortByTag</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sort the IFD entries by tag. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a67f29417445e1ff81dfedbd7d42daff"></a><!-- doxytag: member="Exiv2::Ifd::begin" ref="a67f29417445e1ff81dfedbd7d42daff" args="()" -->
<a class="el" href="classExiv2_1_1Ifd.html#9c93a8ce8a9645aa66c152641a91fb56">iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#a67f29417445e1ff81dfedbd7d42daff">begin</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">The first entry. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="ea062007f866b97a9ce6867fb1e52fe1"></a><!-- doxytag: member="Exiv2::Ifd::end" ref="ea062007f866b97a9ce6867fb1e52fe1" args="()" -->
<a class="el" href="classExiv2_1_1Ifd.html#9c93a8ce8a9645aa66c152641a91fb56">iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#ea062007f866b97a9ce6867fb1e52fe1">end</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">End of the entries. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="7d69be6d51afd457322ffa055fcfc568"></a><!-- doxytag: member="Exiv2::Ifd::findIdx" ref="7d69be6d51afd457322ffa055fcfc568" args="(int idx)" -->
<a class="el" href="classExiv2_1_1Ifd.html#9c93a8ce8a9645aa66c152641a91fb56">iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#7d69be6d51afd457322ffa055fcfc568">findIdx</a> (int idx)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find an IFD entry by idx, return an iterator into the entries list. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="9f2ed8194ec2f2a92d400807102cce43"></a><!-- doxytag: member="Exiv2::Ifd::findTag" ref="9f2ed8194ec2f2a92d400807102cce43" args="(uint16_t tag)" -->
<a class="el" href="classExiv2_1_1Ifd.html#9c93a8ce8a9645aa66c152641a91fb56">iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#9f2ed8194ec2f2a92d400807102cce43">findTag</a> (uint16_t tag)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find an IFD entry by tag, return an iterator into the entries list. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#fdc96f99d251a70a77e16d24cde6aaf2">updateBase</a> (<a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *pNewBase)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Update the base pointer of the <a class="el" href="classExiv2_1_1Ifd.html" title="Models an IFD (Image File Directory).">Ifd</a> and all entries to <em>pNewBase</em>.  <a href="#fdc96f99d251a70a77e16d24cde6aaf2"></a><br></td></tr>
<tr><td colspan="2"><div class="groupHeader">Accessors</div></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#bff72dd26220e5f6d30288f45af42e0a">readSubIfd</a> (<a class="el" href="classExiv2_1_1Ifd.html">Ifd</a> &amp;dest, const <a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *buf, long len, <a class="el" href="namespaceExiv2.html#94c225faf6d6c611a3828fae1c28efa6">ByteOrder</a> byteOrder, uint16_t tag) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read a sub-IFD from the location pointed to by the directory entry with the given tag.  <a href="#bff72dd26220e5f6d30288f45af42e0a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="c8a8b5eeaf0437c846b160f58347b68f"></a><!-- doxytag: member="Exiv2::Ifd::alloc" ref="c8a8b5eeaf0437c846b160f58347b68f" args="() const " -->
bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#c8a8b5eeaf0437c846b160f58347b68f">alloc</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the memory allocation mode, see the <a class="el" href="classExiv2_1_1Ifd.html" title="Models an IFD (Image File Directory).">Ifd</a> class description for details. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="3f3c2d53d5e2a46b8de4219a062981b6"></a><!-- doxytag: member="Exiv2::Ifd::begin" ref="3f3c2d53d5e2a46b8de4219a062981b6" args="() const " -->
<a class="el" href="classExiv2_1_1Ifd.html#e1a940634eeaaf03e3635b666ee8ab06">const_iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#3f3c2d53d5e2a46b8de4219a062981b6">begin</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">The first entry. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="8b9d389689153948e6a55a5bed90596d"></a><!-- doxytag: member="Exiv2::Ifd::end" ref="8b9d389689153948e6a55a5bed90596d" args="() const " -->
<a class="el" href="classExiv2_1_1Ifd.html#e1a940634eeaaf03e3635b666ee8ab06">const_iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#8b9d389689153948e6a55a5bed90596d">end</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">End of the entries. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="761f977494df27c2ba2e65bc90976cde"></a><!-- doxytag: member="Exiv2::Ifd::findIdx" ref="761f977494df27c2ba2e65bc90976cde" args="(int idx) const " -->
<a class="el" href="classExiv2_1_1Ifd.html#e1a940634eeaaf03e3635b666ee8ab06">const_iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#761f977494df27c2ba2e65bc90976cde">findIdx</a> (int idx) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find an IFD entry by idx, return a const iterator into the entries list. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="8cbcba35cb4ab1ffd589aa8864cc1ebd"></a><!-- doxytag: member="Exiv2::Ifd::findTag" ref="8cbcba35cb4ab1ffd589aa8864cc1ebd" args="(uint16_t tag) const " -->
<a class="el" href="classExiv2_1_1Ifd.html#e1a940634eeaaf03e3635b666ee8ab06">const_iterator</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#8cbcba35cb4ab1ffd589aa8864cc1ebd">findTag</a> (uint16_t tag) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Find an IFD entry by tag, return a const iterator into the entries list. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="00a4292e936211c946594be03bad055e"></a><!-- doxytag: member="Exiv2::Ifd::ifdId" ref="00a4292e936211c946594be03bad055e" args="() const " -->
<a class="el" href="namespaceExiv2.html#1615152767a506a955c9d13443b56b62">IfdId</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#00a4292e936211c946594be03bad055e">ifdId</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the IfdId of the IFD. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="fb2195a0b29a87cfff6aa35437b47a9e"></a><!-- doxytag: member="Exiv2::Ifd::offset" ref="fb2195a0b29a87cfff6aa35437b47a9e" args="() const " -->
long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#fb2195a0b29a87cfff6aa35437b47a9e">offset</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the offset of the IFD from the start of the TIFF header. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="ff751d7b774be46c37235951212321cc"></a><!-- doxytag: member="Exiv2::Ifd::dataOffset" ref="ff751d7b774be46c37235951212321cc" args="() const " -->
long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#ff751d7b774be46c37235951212321cc">dataOffset</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the offset of the first data entry outside of the IFD from the start of the TIFF header, return 0 if there is none. The data offset is determined when the IFD is read. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="5c7a475416b7d03f5467c2b0a3f8a297"></a><!-- doxytag: member="Exiv2::Ifd::next" ref="5c7a475416b7d03f5467c2b0a3f8a297" args="() const " -->
uint32_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#5c7a475416b7d03f5467c2b0a3f8a297">next</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the offset to the next IFD from the start of the TIFF header. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="0d2baaaa5da6e435134c688faa435b24"></a><!-- doxytag: member="Exiv2::Ifd::count" ref="0d2baaaa5da6e435134c688faa435b24" args="() const " -->
long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#0d2baaaa5da6e435134c688faa435b24">count</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the number of directory entries in the IFD. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a12417574ede7fc602ec2bd4c8bedfe9"></a><!-- doxytag: member="Exiv2::Ifd::size" ref="a12417574ede7fc602ec2bd4c8bedfe9" args="() const " -->
long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#a12417574ede7fc602ec2bd4c8bedfe9">size</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the size of this IFD in bytes (IFD only, without data). <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="ed3dbf3d4dbf003df41acbd4587df8a3"></a><!-- doxytag: member="Exiv2::Ifd::dataSize" ref="ed3dbf3d4dbf003df41acbd4587df8a3" args="() const " -->
long&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#ed3dbf3d4dbf003df41acbd4587df8a3">dataSize</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the total size of the data of this IFD in bytes; sums the size of all directory entries where size is greater than four plus the size of all data areas, i.e., all data that requires memory outside the IFD directory entries is counted. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="ac4f19f3ee6eccbfd2fce067d03efb1f"></a><!-- doxytag: member="Exiv2::Ifd::print" ref="ac4f19f3ee6eccbfd2fce067d03efb1f" args="(std::ostream &amp;os, const std::string &amp;prefix=&quot;&quot;) const " -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#ac4f19f3ee6eccbfd2fce067d03efb1f">print</a> (std::ostream &amp;os, const std::string &amp;prefix=&quot;&quot;) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Print the IFD in human readable format to the given stream; begin each line with prefix. <br></td></tr>
<tr><td colspan="2"><br><h2>Friends</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="2c0727f3ca00ed901f4657185944f16c"></a><!-- doxytag: member="Exiv2::Ifd::cmpPreEntriesByOffset" ref="2c0727f3ca00ed901f4657185944f16c" args="(const PreEntry &amp;, const PreEntry &amp;)" -->
bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classExiv2_1_1Ifd.html#2c0727f3ca00ed901f4657185944f16c">cmpPreEntriesByOffset</a> (const PreEntry &amp;, const PreEntry &amp;)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">cmpPreEntriesByOffset needs to know about PreEntry, that's all. <br></td></tr>
<tr><td colspan="2"><br><h2>Classes</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><b>PreEntry</b></td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Helper structure to build IFD entries. <br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Models an IFD (Image File Directory). 
<p>
This class models an IFD as described in the TIFF 6.0 specification.<p>
An instance of class Ifd can operate in two modes, one that allocates and deallocates the memory required to store data, and one that doesn't perform such memory management. <br>
An external data buffer (not managed by Ifd) is needed for an instance of Ifd which operates in no memory management mode. The Ifd will maintain only pointers into this buffer. <br>
 The mode without memory management is used to make "non-intrusive write support" possible. This allows writing to Exif data of an image without changing the data layout of the Exif data, to maximize chances that tag data, which the Exif reader may not understand (e.g., the Makernote) remains valid. A "non-intrusive write operation" is the modification of tag data without increasing the data size.<p>
<dl class="note" compact><dt><b>Note:</b></dt><dd>Use the mode with memory management (the default) if you are unsure or if these memory management considerations are of no concern to you.<p>
The two different modes imply completely different copy and assignment behaviours, with the first resulting in entirely separate classes and the second mode resulting in multiple classes using one and the same data buffer. </dd></dl>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="8d86b9dfa71fb413978822ed388d5f78"></a><!-- doxytag: member="Exiv2::Ifd::read" ref="8d86b9dfa71fb413978822ed388d5f78" args="(const byte *buf, long len, long start, ByteOrder byteOrder, long shift=0)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int Exiv2::Ifd::read           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *&nbsp;</td>
          <td class="paramname"> <em>buf</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">long&nbsp;</td>
          <td class="paramname"> <em>len</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">long&nbsp;</td>
          <td class="paramname"> <em>start</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceExiv2.html#94c225faf6d6c611a3828fae1c28efa6">ByteOrder</a>&nbsp;</td>
          <td class="paramname"> <em>byteOrder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">long&nbsp;</td>
          <td class="paramname"> <em>shift</em> = <code>0</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Read a complete IFD and its data from a data buffer. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>buf</em>&nbsp;</td><td>Pointer to the Exif data buffer that contains the IFD to decode. Usually, the buffer will contain all Exif data starting from the TIFF header. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>len</em>&nbsp;</td><td>Number of bytes in the Exif data buffer. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>start</em>&nbsp;</td><td>IFD starts at buf + start. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>byteOrder</em>&nbsp;</td><td>Applicable byte order (little or big endian). </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>shift</em>&nbsp;</td><td>IFD offsets are relative to buf + shift.</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 if successful;<br>
 6 if the data buffer is too small, e.g., if an offset points beyond the provided buffer. The IFD is cleared in this case. </dd></dl>

</div>
</div><p>
<a class="anchor" name="e4111e2b5234b5dab141e4fd7194eabd"></a><!-- doxytag: member="Exiv2::Ifd::copy" ref="e4111e2b5234b5dab141e4fd7194eabd" args="(byte *buf, ByteOrder byteOrder, long offset=0)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">long Exiv2::Ifd::copy           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *&nbsp;</td>
          <td class="paramname"> <em>buf</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceExiv2.html#94c225faf6d6c611a3828fae1c28efa6">ByteOrder</a>&nbsp;</td>
          <td class="paramname"> <em>byteOrder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">long&nbsp;</td>
          <td class="paramname"> <em>offset</em> = <code>0</code></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Copy the IFD to a data array, update the offsets of the IFD and all its entries, return the number of bytes written. 
<p>
First the number of IFD entries is written (2 bytes), followed by all directory entries: tag (2), type (2), number of data components (4) and offset to the data or the data, if it occupies not more than four bytes (4). The directory entries are followed by the offset of the next IFD (4). All these fields are encoded according to the byte order argument. Data that doesn't fit into the offset fields follows immediately after the IFD entries. The offsets in the IFD are set to correctly point to the data fields, using the offset parameter or the offset of the IFD.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>buf</em>&nbsp;</td><td>Pointer to the data buffer. The user must ensure that the buffer has enough memory. Otherwise the call results in undefined behaviour. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>byteOrder</em>&nbsp;</td><td>Applicable byte order (little or big endian). </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>offset</em>&nbsp;</td><td>Target offset from the start of the TIFF header of the data array. The IFD offsets will be adjusted as necessary. If not given, then it is assumed that the IFD will remain at its original position, i.e., the offset of the IFD will be used. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Returns the number of characters written. </dd></dl>

</div>
</div><p>
<a class="anchor" name="fdc96f99d251a70a77e16d24cde6aaf2"></a><!-- doxytag: member="Exiv2::Ifd::updateBase" ref="fdc96f99d251a70a77e16d24cde6aaf2" args="(byte *pNewBase)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a>* Exiv2::Ifd::updateBase           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *&nbsp;</td>
          <td class="paramname"> <em>pNewBase</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Update the base pointer of the <a class="el" href="classExiv2_1_1Ifd.html" title="Models an IFD (Image File Directory).">Ifd</a> and all entries to <em>pNewBase</em>. 
<p>
Allows to re-locate the underlying data buffer to a new location <em>pNewBase</em>. This method only has an effect in non-alloc mode.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pNewBase</em>&nbsp;</td><td>Pointer to the new data buffer</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Old base pointer or 0 if called in alloc mode </dd></dl>

</div>
</div><p>
<a class="anchor" name="bff72dd26220e5f6d30288f45af42e0a"></a><!-- doxytag: member="Exiv2::Ifd::readSubIfd" ref="bff72dd26220e5f6d30288f45af42e0a" args="(Ifd &amp;dest, const byte *buf, long len, ByteOrder byteOrder, uint16_t tag) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int Exiv2::Ifd::readSubIfd           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classExiv2_1_1Ifd.html">Ifd</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>dest</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="namespaceExiv2.html#16f60a5bd4207fe155f6cf93a15efa72">byte</a> *&nbsp;</td>
          <td class="paramname"> <em>buf</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">long&nbsp;</td>
          <td class="paramname"> <em>len</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceExiv2.html#94c225faf6d6c611a3828fae1c28efa6">ByteOrder</a>&nbsp;</td>
          <td class="paramname"> <em>byteOrder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint16_t&nbsp;</td>
          <td class="paramname"> <em>tag</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Read a sub-IFD from the location pointed to by the directory entry with the given tag. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dest</em>&nbsp;</td><td>References the destination IFD. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>buf</em>&nbsp;</td><td>The data buffer to read from. The buffer must contain all Exif data starting from the TIFF header. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>len</em>&nbsp;</td><td>Number of bytes in the data buffer </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>byteOrder</em>&nbsp;</td><td>Applicable byte order (little or big endian). </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>tag</em>&nbsp;</td><td><a class="el" href="namespaceExiv2_1_1Tag.html">Tag</a> to look for.</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>0 if successful;<br>
 6 if reading the sub-IFD failed (see <a class="el" href="classExiv2_1_1Ifd.html#8d86b9dfa71fb413978822ed388d5f78" title="Read a complete IFD and its data from a data buffer.">read()</a> above) or the location pointed to by the directory entry with the given tag is outside of the data buffer.</dd></dl>
<dl class="note" compact><dt><b>Note:</b></dt><dd>It is not considered an error if the tag cannot be found in the IFD. 0 is returned and no action is taken in this case. </dd></dl>

</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="ifd_8hpp.html">ifd.hpp</a></ul>
<hr size="1"><address style="text-align: right;"><small>Generated on Tue Feb 5 11:51:04 2008 for Exiv2 by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.4 </small></address>
</body>
</html>