1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
3
<title>FLAC++/metadata.h: metadata level 2 interface</title>
4
<link href="doxygen.css" rel="stylesheet" type="text/css">
6
<!-- Generated by Doxygen 1.2.14 -->
8
<a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="modules.html">Modules</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="classes.html">Alphabetical List</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="globals.html">File Members</a> </center>
9
<hr><h1>FLAC++/metadata.h: metadata level 2 interface<br>
11
[<a class="el" href="group__flacpp__metadata.html">FLAC++/metadata.h: metadata interfaces</a>]</small>
12
</h1>Level 2 metadata iterator.
13
<a href="#_details">More...</a><table border=0 cellpadding=0 cellspacing=0>
14
<tr><td colspan=2><br><h2>Compounds</h2></td></tr>
15
<tr><td nowrap align=right valign=top>class </td><td valign=bottom><a class="el" href="classFLAC_1_1Metadata_1_1Chain.html">FLAC::Metadata::Chain</a></td></tr>
16
<tr><td nowrap align=right valign=top>class </td><td valign=bottom><a class="el" href="classFLAC_1_1Metadata_1_1Iterator.html">FLAC::Metadata::Iterator</a></td></tr>
18
<hr><a name="_details"></a><h2>Detailed Description</h2>
19
Level 2 metadata iterator.
23
The flow through the iterator in the C++ layer is similar to the C layer:<ul>
24
<li>Create a Chain instance<li>Check Chain::is_valid()<li>Call Chain::read() and check the return<li>Traverse and/or edit with an Iterator or with Chain::merge_padding() or Chain::sort_padding()<li>Write changes back to FLAC file with Chain::write()<li>Destroy the Chain instance</ul>
25
The ownership of pointers in the C++ layer is slightly different than in the C layer, i.e.<ul>
26
<li>The objects returned by Iterator::get_block() are NOT owned by the iterator and should be deleted by the caller when finished, BUT, when you modify the block, it will directly edit what's in the chain and you do not need to call Iterator::set_block(). However the changes will not be reflected in the FLAC file until the chain is written with Chain::write().<li>When you pass an object to Iterator::set_block(), Iterator::insert_block_before(), or Iterator::insert_block_after(), the iterator takes ownership of the block and it will be deleted by the chain.</ul>
27
See the <a class="el" href="group__flac__metadata__level2.html">C layer equivalent</a> for more. <hr><address><small>Generated on Sat Jan 25 10:44:58 2003 for FLAC by
28
<a href="http://www.doxygen.org/index.html">
29
<img src="doxygen.gif" alt="doxygen" align="middle" border=0
30
width=110 height=53></a>1.2.14 written by <a href="mailto:dimitri@stack.nl">Dimitri van Heesch</a>,
31
© 1997-2002</small></address>