forked from boostorg/fusion
merged fusion from the trunk
[SVN r63560]
This commit is contained in:
@ -22,7 +22,7 @@
|
||||
<div class="spirit-nav">
|
||||
<a accesskey="p" href="../extension.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../extension.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="sequence_facade.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
|
||||
</div>
|
||||
<div class="section" title="The Full Extension Mechanism">
|
||||
<div class="section">
|
||||
<div class="titlepage"><div><div><h3 class="title">
|
||||
<a name="fusion.extension.ext_full"></a><a class="link" href="ext_full.html" title="The Full Extension Mechanism"> The Full Extension Mechanism</a>
|
||||
</h3></div></div></div>
|
||||
@ -37,19 +37,20 @@
|
||||
</p>
|
||||
<div class="orderedlist"><ol class="orderedlist" type="1">
|
||||
<li class="listitem">
|
||||
Enable the <a class="link" href="../notes.html#fusion.notes.tag_dispatching"><span class="emphasis"><em>tag dispatching</em></span></a>
|
||||
mechanism used by Fusion for your sequence type
|
||||
</li>
|
||||
Enable the <a class="link" href="../notes.html#fusion.notes.tag_dispatching"><span class="emphasis"><em>tag
|
||||
dispatching</em></span></a> mechanism used by Fusion for your sequence
|
||||
type
|
||||
</li>
|
||||
<li class="listitem">
|
||||
Design an iterator type for the sequence
|
||||
</li>
|
||||
Design an iterator type for the sequence
|
||||
</li>
|
||||
<li class="listitem">
|
||||
Provide specialized behaviour for the intrinsic operations of the new Fusion
|
||||
sequence
|
||||
</li>
|
||||
Provide specialized behaviour for the intrinsic operations of the new
|
||||
Fusion sequence
|
||||
</li>
|
||||
</ol></div>
|
||||
<a name="fusion.extension.ext_full.our_example"></a><h5>
|
||||
<a name="id836756"></a>
|
||||
<a name="id1076190"></a>
|
||||
<a class="link" href="ext_full.html#fusion.extension.ext_full.our_example">Our example</a>
|
||||
</h5>
|
||||
<p>
|
||||
@ -79,7 +80,7 @@
|
||||
Start</a> guide.
|
||||
</p>
|
||||
<a name="fusion.extension.ext_full.enabling_tag_dispatching"></a><h5>
|
||||
<a name="id836960"></a>
|
||||
<a name="id1076394"></a>
|
||||
<a class="link" href="ext_full.html#fusion.extension.ext_full.enabling_tag_dispatching">Enabling
|
||||
Tag Dispatching</a>
|
||||
</h5>
|
||||
@ -120,7 +121,7 @@
|
||||
<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">tag_of</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
|
||||
</pre>
|
||||
<a name="fusion.extension.ext_full.designing_a_suitable_iterator"></a><h5>
|
||||
<a name="id837396"></a>
|
||||
<a name="id1076830"></a>
|
||||
<a class="link" href="ext_full.html#fusion.extension.ext_full.designing_a_suitable_iterator">Designing
|
||||
a suitable iterator</a>
|
||||
</h5>
|
||||
@ -154,23 +155,23 @@
|
||||
</p>
|
||||
<div class="orderedlist"><ol class="orderedlist" type="1">
|
||||
<li class="listitem">
|
||||
The iterator is parameterized by the type it is iterating over, and the
|
||||
index of the current element.
|
||||
</li>
|
||||
The iterator is parameterized by the type it is iterating over, and the
|
||||
index of the current element.
|
||||
</li>
|
||||
<li class="listitem">
|
||||
The typedefs <code class="computeroutput"><span class="identifier">struct_type</span></code>
|
||||
and <code class="computeroutput"><span class="identifier">index</span></code> provide convenient
|
||||
access to information we will need later in the implementation.
|
||||
</li>
|
||||
The typedefs <code class="computeroutput"><span class="identifier">struct_type</span></code>
|
||||
and <code class="computeroutput"><span class="identifier">index</span></code> provide convenient
|
||||
access to information we will need later in the implementation.
|
||||
</li>
|
||||
<li class="listitem">
|
||||
The typedef <code class="computeroutput"><span class="identifier">category</span></code> allows
|
||||
the <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><a class="link" href="../support/category_of.html" title="category_of"><code class="computeroutput"><span class="identifier">category_of</span></code></a></code>
|
||||
metafunction to establish the traversal category of the iterator.
|
||||
</li>
|
||||
The typedef <code class="computeroutput"><span class="identifier">category</span></code>
|
||||
allows the <code class="computeroutput"><span class="identifier">traits</span><span class="special">::</span><a class="link" href="../support/category_of.html" title="category_of"><code class="computeroutput"><span class="identifier">category_of</span></code></a></code>
|
||||
metafunction to establish the traversal category of the iterator.
|
||||
</li>
|
||||
<li class="listitem">
|
||||
The constructor stores a reference to the <code class="computeroutput"><span class="identifier">example_struct</span></code>
|
||||
being iterated over.
|
||||
</li>
|
||||
The constructor stores a reference to the <code class="computeroutput"><span class="identifier">example_struct</span></code>
|
||||
being iterated over.
|
||||
</li>
|
||||
</ol></div>
|
||||
<p>
|
||||
We also need to enable <a class="link" href="../notes.html#fusion.notes.tag_dispatching"><span class="emphasis"><em>tag
|
||||
@ -182,7 +183,7 @@
|
||||
clearer as we add features to our implementation.
|
||||
</p>
|
||||
<a name="fusion.extension.ext_full.a_first_couple_of_instructive_features"></a><h5>
|
||||
<a name="id837854"></a>
|
||||
<a name="id1077302"></a>
|
||||
<a class="link" href="ext_full.html#fusion.extension.ext_full.a_first_couple_of_instructive_features">A
|
||||
first couple of instructive features</a>
|
||||
</h5>
|
||||
@ -308,7 +309,7 @@
|
||||
sequence. We also require a little bit of metaprogramming to return <code class="computeroutput"><span class="keyword">const</span></code> references if the underlying sequence
|
||||
is const.
|
||||
</p>
|
||||
<div class="note" title="Note"><table border="0" summary="Note">
|
||||
<div class="note"><table border="0" summary="Note">
|
||||
<tr>
|
||||
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../../../doc/html/images/note.png"></td>
|
||||
<th align="left">Note</th>
|
||||
@ -322,7 +323,7 @@
|
||||
</p></td></tr>
|
||||
</table></div>
|
||||
<a name="fusion.extension.ext_full.implementing_the_remaining_iterator_functionality"></a><h5>
|
||||
<a name="id840585"></a>
|
||||
<a name="id1080579"></a>
|
||||
<a class="link" href="ext_full.html#fusion.extension.ext_full.implementing_the_remaining_iterator_functionality">Implementing
|
||||
the remaining iterator functionality</a>
|
||||
</h5>
|
||||
@ -373,7 +374,7 @@
|
||||
are provided in the example code.
|
||||
</p>
|
||||
<a name="fusion.extension.ext_full.implementing_the_intrinsic_functions_of_the_sequence"></a><h5>
|
||||
<a name="id841029"></a>
|
||||
<a name="id1081023"></a>
|
||||
<a class="link" href="ext_full.html#fusion.extension.ext_full.implementing_the_intrinsic_functions_of_the_sequence">Implementing
|
||||
the intrinsic functions of the sequence</a>
|
||||
</h5>
|
||||
@ -429,7 +430,7 @@
|
||||
<code class="computeroutput"><span class="identifier">value_at_impl</span></code> and <code class="computeroutput"><span class="identifier">at_impl</span></code>.
|
||||
</p>
|
||||
<a name="fusion.extension.ext_full.enabling_our_type_as_an_associative_sequence"></a><h5>
|
||||
<a name="id841441"></a>
|
||||
<a name="id1081435"></a>
|
||||
<a class="link" href="ext_full.html#fusion.extension.ext_full.enabling_our_type_as_an_associative_sequence">Enabling
|
||||
our type as an associative sequence</a>
|
||||
</h5>
|
||||
@ -493,7 +494,7 @@
|
||||
are provided in the example code.
|
||||
</p>
|
||||
<a name="fusion.extension.ext_full.summary"></a><h5>
|
||||
<a name="id843247"></a>
|
||||
<a name="id1082696"></a>
|
||||
<a class="link" href="ext_full.html#fusion.extension.ext_full.summary">Summary</a>
|
||||
</h5>
|
||||
<p>
|
||||
|
@ -22,12 +22,12 @@
|
||||
<div class="spirit-nav">
|
||||
<a accesskey="p" href="sequence_facade.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../extension.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="../functional.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
|
||||
</div>
|
||||
<div class="section" title="Iterator Facade">
|
||||
<div class="section">
|
||||
<div class="titlepage"><div><div><h3 class="title">
|
||||
<a name="fusion.extension.iterator_facade"></a><a class="link" href="iterator_facade.html" title="Iterator Facade">Iterator Facade</a>
|
||||
</h3></div></div></div>
|
||||
<a name="fusion.extension.iterator_facade.description"></a><h5>
|
||||
<a name="id844407"></a>
|
||||
<a name="id1083855"></a>
|
||||
<a class="link" href="iterator_facade.html#fusion.extension.iterator_facade.description">Description</a>
|
||||
</h5>
|
||||
<p>
|
||||
@ -36,14 +36,14 @@
|
||||
iterator.
|
||||
</p>
|
||||
<a name="fusion.extension.iterator_facade.synopsis"></a><h5>
|
||||
<a name="id844433"></a>
|
||||
<a name="id1083881"></a>
|
||||
<a class="link" href="iterator_facade.html#fusion.extension.iterator_facade.synopsis">Synopsis</a>
|
||||
</h5>
|
||||
<pre class="programlisting"><span class="keyword">template</span><span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Derived</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">TravesalTag</span><span class="special">></span>
|
||||
<span class="keyword">struct</span> <span class="identifier">iterator_facade</span><span class="special">;</span>
|
||||
</pre>
|
||||
<a name="fusion.extension.iterator_facade.usage"></a><h5>
|
||||
<a name="id844497"></a>
|
||||
<a name="id1083945"></a>
|
||||
<a class="link" href="iterator_facade.html#fusion.extension.iterator_facade.usage">Usage</a>
|
||||
</h5>
|
||||
<p>
|
||||
@ -57,7 +57,7 @@
|
||||
type.
|
||||
</p>
|
||||
<div class="table">
|
||||
<a name="id844513"></a><p class="title"><b>Table 1.97. Parameters</b></p>
|
||||
<a name="id1083962"></a><p class="title"><b>Table 1.103. Parameters</b></p>
|
||||
<div class="table-contents"><table class="table" summary="Parameters">
|
||||
<colgroup>
|
||||
<col>
|
||||
@ -106,7 +106,7 @@
|
||||
</table></div>
|
||||
</div>
|
||||
<br class="table-break"><div class="table">
|
||||
<a name="id844638"></a><p class="title"><b>Table 1.98. Key Expressions</b></p>
|
||||
<a name="id1084086"></a><p class="title"><b>Table 1.104. Key Expressions</b></p>
|
||||
<div class="table-contents"><table class="table" summary="Key Expressions">
|
||||
<colgroup>
|
||||
<col>
|
||||
@ -439,14 +439,14 @@
|
||||
</table></div>
|
||||
</div>
|
||||
<br class="table-break"><a name="fusion.extension.iterator_facade.header"></a><h5>
|
||||
<a name="id846657"></a>
|
||||
<a name="id1085559"></a>
|
||||
<a class="link" href="iterator_facade.html#fusion.extension.iterator_facade.header">Header</a>
|
||||
</h5>
|
||||
<pre class="programlisting"><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">iterator</span><span class="special">/</span><span class="identifier">iterator_facade</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
|
||||
<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">iterator_facade</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
|
||||
</pre>
|
||||
<a name="fusion.extension.iterator_facade.example"></a><h5>
|
||||
<a name="id846765"></a>
|
||||
<a name="id1085667"></a>
|
||||
<a class="link" href="iterator_facade.html#fusion.extension.iterator_facade.example">Example</a>
|
||||
</h5>
|
||||
<p>
|
||||
|
@ -22,12 +22,12 @@
|
||||
<div class="spirit-nav">
|
||||
<a accesskey="p" href="ext_full.html"><img src="../../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../extension.html"><img src="../../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="iterator_facade.html"><img src="../../../../../../doc/html/images/next.png" alt="Next"></a>
|
||||
</div>
|
||||
<div class="section" title="Sequence Facade">
|
||||
<div class="section">
|
||||
<div class="titlepage"><div><div><h3 class="title">
|
||||
<a name="fusion.extension.sequence_facade"></a><a class="link" href="sequence_facade.html" title="Sequence Facade">Sequence Facade</a>
|
||||
</h3></div></div></div>
|
||||
<a name="fusion.extension.sequence_facade.description"></a><h5>
|
||||
<a name="id843312"></a>
|
||||
<a name="id1082760"></a>
|
||||
<a class="link" href="sequence_facade.html#fusion.extension.sequence_facade.description">Description</a>
|
||||
</h5>
|
||||
<p>
|
||||
@ -36,14 +36,14 @@
|
||||
iterator.
|
||||
</p>
|
||||
<a name="fusion.extension.sequence_facade.synopsis"></a><h5>
|
||||
<a name="id843339"></a>
|
||||
<a name="id1082787"></a>
|
||||
<a class="link" href="sequence_facade.html#fusion.extension.sequence_facade.synopsis">Synopsis</a>
|
||||
</h5>
|
||||
<pre class="programlisting"><span class="keyword">template</span><span class="special"><</span><span class="keyword">typename</span> <span class="identifier">Derived</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">TravesalTag</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">IsView</span> <span class="special">=</span> <span class="identifier">mpl</span><span class="special">::</span><span class="identifier">false_</span><span class="special">></span>
|
||||
<span class="keyword">struct</span> <span class="identifier">sequence_facade</span><span class="special">;</span>
|
||||
</pre>
|
||||
<a name="fusion.extension.sequence_facade.usage"></a><h5>
|
||||
<a name="id843432"></a>
|
||||
<a name="id1082880"></a>
|
||||
<a class="link" href="sequence_facade.html#fusion.extension.sequence_facade.usage">Usage</a>
|
||||
</h5>
|
||||
<p>
|
||||
@ -59,7 +59,7 @@
|
||||
type.
|
||||
</p>
|
||||
<div class="table">
|
||||
<a name="id843484"></a><p class="title"><b>Table 1.95. Parameters</b></p>
|
||||
<a name="id1082932"></a><p class="title"><b>Table 1.101. Parameters</b></p>
|
||||
<div class="table-contents"><table class="table" summary="Parameters">
|
||||
<colgroup>
|
||||
<col>
|
||||
@ -107,7 +107,7 @@
|
||||
</table></div>
|
||||
</div>
|
||||
<br class="table-break"><div class="table">
|
||||
<a name="id843594"></a><p class="title"><b>Table 1.96. Key Expressions</b></p>
|
||||
<a name="id1083042"></a><p class="title"><b>Table 1.102. Key Expressions</b></p>
|
||||
<div class="table-contents"><table class="table" summary="Key Expressions">
|
||||
<colgroup>
|
||||
<col>
|
||||
@ -244,14 +244,14 @@
|
||||
</table></div>
|
||||
</div>
|
||||
<br class="table-break"><a name="fusion.extension.sequence_facade.include"></a><h5>
|
||||
<a name="id844261"></a>
|
||||
<a name="id1083710"></a>
|
||||
<a class="link" href="sequence_facade.html#fusion.extension.sequence_facade.include">Include</a>
|
||||
</h5>
|
||||
<pre class="programlisting"><span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">sequence</span><span class="special">/</span><span class="identifier">sequence_facade</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
|
||||
<span class="preprocessor">#include</span> <span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">fusion</span><span class="special">/</span><span class="identifier">include</span><span class="special">/</span><span class="identifier">sequence_facade</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span>
|
||||
</pre>
|
||||
<a name="fusion.extension.sequence_facade.example"></a><h5>
|
||||
<a name="id844369"></a>
|
||||
<a name="id1083818"></a>
|
||||
<a class="link" href="sequence_facade.html#fusion.extension.sequence_facade.example">Example</a>
|
||||
</h5>
|
||||
<p>
|
||||
|
Reference in New Issue
Block a user