resolved some issues with transform iterator

[SVN r21638]
This commit is contained in:
Jeremy Siek
2004-01-12 18:38:32 +00:00
parent 8181625365
commit b2407b0191
6 changed files with 204 additions and 137 deletions

View File

@ -40,11 +40,9 @@ Railway Operation and Construction</a></td></tr>
</tr>
</tbody>
</table>
<p>The transform iterator adapts an iterator by applying some function
object to the result of dereferencing the iterator. In other words,
the <tt class="literal"><span class="pre">operator*</span></tt> of the transform iterator first dereferences the
base iterator, passes the result of this to the function object, and
then returns the result.</p>
<p>The transform iterator adapts an iterator by modifying the
<tt class="literal"><span class="pre">operator*</span></tt> to apply a function object to the result of
dereferencing the iterator and returning the result.</p>
<div class="contents topic" id="table-of-contents">
<p class="topic-title"><a name="table-of-contents">Table of Contents</a></p>
<ul class="simple">
@ -72,8 +70,8 @@ public:
template&lt;class F2, class I2, class R2, class V2&gt;
transform_iterator(
transform_iterator&lt;F2, I2, R2, V2&gt; const&amp; t
, typename enable_if_convertible&lt;I2, Iterator&gt;::type* = 0 // exposition
, typename enable_if_convertible&lt;F2, UnaryFunction&gt;::type* = 0 // exposition
, typename enable_if_convertible&lt;I2, Iterator&gt;::type* = 0 // exposition only
, typename enable_if_convertible&lt;F2, UnaryFunction&gt;::type* = 0 // exposition only
);
Iterator base() const;
UnaryFunction functor() const;
@ -81,8 +79,8 @@ public:
transform_iterator&amp; operator++();
transform_iterator&amp; operator--();
private:
Iterator m_iterator; // exposition
UnaryFunction m_f; // exposition
Iterator m_iterator; // exposition only
UnaryFunction m_f; // exposition only
};
</pre>
</div>
@ -273,7 +271,7 @@ adding 4 to each element in the array:
<hr class="footer"/>
<div class="footer">
<a class="reference" href="transform_iterator.rst">View document source</a>.
Generated on: 2004-01-12 16:04 UTC.
Generated on: 2004-01-12 18:35 UTC.
Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
</div>
</body>