Boost logo

Boost-Commit :

From: chochlik_at_[hidden]
Date: 2008-07-16 12:28:41


Author: matus.chochlik
Date: 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
New Revision: 47475
URL: http://svn.boost.org/trac/boost/changeset/47475

Log:
[mirror 0.2.x]
- Updated the docs
- Added two more examples to the docs
Added:
   sandbox/mirror/libs/mirror/doc/samples/usage_meta_namespace_03.xml (contents, props changed)
   sandbox/mirror/libs/mirror/doc/samples/usage_meta_type_04.xml (contents, props changed)
Text files modified:
   sandbox/mirror/doc/html/boost/mirror/meta_class.html | 8 ++--
   sandbox/mirror/doc/html/boost/mirror/meta_namespace.html | 70 ++++++++++++++++++++++++++++++++++-----
   sandbox/mirror/doc/html/boost/mirror/meta_type.html | 70 ++++++++++++++++++++++++++++++++++-----
   sandbox/mirror/doc/html/char_type_switch.html | 2
   sandbox/mirror/doc/html/index.html | 2
   sandbox/mirror/doc/html/mirror.html | 2
   sandbox/mirror/libs/mirror/doc/reference/meta_namespace.xml | 17 +++++++++
   sandbox/mirror/libs/mirror/doc/reference/meta_type.xml | 17 +++++++++
   8 files changed, 161 insertions(+), 27 deletions(-)

Modified: sandbox/mirror/doc/html/boost/mirror/meta_class.html
==============================================================================
--- sandbox/mirror/doc/html/boost/mirror/meta_class.html (original)
+++ sandbox/mirror/doc/html/boost/mirror/meta_class.html 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -44,16 +44,16 @@
                                         </em></span>
 {
 <span class="bold"><strong>public</strong></span>:
- <span class="emphasis"><em>// <a class="link" href="meta_class.html#id513376-bbtypes">types</a></em></span>
+ <span class="emphasis"><em>// <a class="link" href="meta_class.html#id612141-bbtypes">types</a></em></span>
   <span class="bold"><strong>typedef</strong></span> <span class="emphasis"><em>unspecified</em></span> <a class="link" href="meta_class.html#boost.mirror.meta_class.base_classes">base_classes</a>;
   <span class="bold"><strong>typedef</strong></span> <span class="emphasis"><em>unspecified</em></span> <a class="link" href="meta_class.html#boost.mirror.meta_class.attributes">attributes</a>;
   <span class="bold"><strong>typedef</strong></span> <span class="emphasis"><em>unspecified</em></span> <a class="link" href="meta_class.html#boost.mirror.meta_class.all_attributes">all_attributes</a>;
 };</pre></div>
 <div class="refsect1" lang="en">
-<a name="id699328"></a><h2>Description</h2>
+<a name="id696193"></a><h2>Description</h2>
 <div class="refsect2" lang="en">
-<a name="id699332"></a><h3>
-<a name="id513376-bbtypes"></a><code class="computeroutput">meta_class</code> public types</h3>
+<a name="id696197"></a><h3>
+<a name="id612141-bbtypes"></a><code class="computeroutput">meta_class</code> public types</h3>
 <div class="orderedlist"><ol type="1">
 <li>
 <p>

Modified: sandbox/mirror/doc/html/boost/mirror/meta_namespace.html
==============================================================================
--- sandbox/mirror/doc/html/boost/mirror/meta_namespace.html (original)
+++ sandbox/mirror/doc/html/boost/mirror/meta_namespace.html 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -45,17 +45,17 @@
 <div xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv"><pre class="synopsis"><span class="bold"><strong>template</strong></span>&lt;<span class="bold"><strong>typename</strong></span> NamespacePlaceholder&gt;
 <span class="bold"><strong>class</strong></span> <a class="link" href="meta_namespace.html" title="Class template meta_namespace">meta_namespace</a> {
 <span class="bold"><strong>public</strong></span>:
- <span class="emphasis"><em>// <a class="link" href="meta_namespace.html#id461075-bbtypes">types</a></em></span>
+ <span class="emphasis"><em>// <a class="link" href="meta_namespace.html#id461012-bbtypes">types</a></em></span>
   <span class="bold"><strong>typedef</strong></span> <span class="emphasis"><em>unspecified</em></span> <a class="link" href="meta_namespace.html#boost.mirror.meta_namespace.scope">scope</a>;
   <span class="bold"><strong>typedef</strong></span> <span class="emphasis"><em>unspecified</em></span> <a class="link" href="meta_namespace.html#boost.mirror.meta_namespace.ancestors">ancestors</a>;
- <span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a class="link" href="meta_namespace.html#id460952-bb">base_name</a>();
- <span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a class="link" href="meta_namespace.html#id460910-bb">full_name</a>();
+ <span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a class="link" href="meta_namespace.html#id460888-bb">base_name</a>();
+ <span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a class="link" href="meta_namespace.html#id460846-bb">full_name</a>();
   <span class="bold"><strong>template</strong></span>&lt;<span class="bold"><strong>bool</strong></span> FullName, <span class="bold"><strong>typename</strong></span> CharT&gt;
     <span class="type"><span class="bold"><strong>const</strong></span> ::std::basic_string&lt;CharT&gt;&amp;</span>
- <a class="link" href="meta_namespace.html#id460856-bb">get_name</a>(::boost::mpl::bool_&lt;FullName&gt;, ::std::char_traits&lt;CharT&gt;);
+ <a class="link" href="meta_namespace.html#id460792-bb">get_name</a>(::boost::mpl::bool_&lt;FullName&gt;, ::std::char_traits&lt;CharT&gt;);
 };</pre></div>
 <div class="refsect1" lang="en">
-<a name="id698062"></a><h2>Description</h2>
+<a name="id694785"></a><h2>Description</h2>
 <p>The specializations of <code class="computeroutput">meta_type</code> can
                                 be used to get meta-information about the reflected types, some at compile-time and some at run-time.
                                 The following examples show type reflection and basic
@@ -69,6 +69,7 @@
 <div class="toc"><dl>
 <dt><span class="section">Example - Basic usage</span></dt>
 <dt><span class="section">Example - Scope and ancestors</span></dt>
+<dt><span class="section">Example - Generic namespace name getter</span></dt>
 </dl></div>
 <div class="section" lang="en">
 <div class="titlepage"><div><div><h6 class="title">
@@ -166,10 +167,59 @@
 }
 </pre>
 </div>
+<div class="section" lang="en">
+<div class="titlepage"><div><div><h6 class="title">
+<a name="mirror.meta_namespace.reference.sample03"></a>Example - Generic namespace name getter</h6></div></div></div>
+<p>The <code class="computeroutput">base_name</code> and the
+ <code class="computeroutput">full_name</code> methods
+ are convenient but not very generic. The <code class="computeroutput">get_name</code>
+ member function allows to specify the character type of the returned string and
+ to specify wheter a full or just the base namespace name should be returned, based
+ on compile time arguments.
+ </p>
+<p>The first argument must be either <code class="computeroutput">mpl::true_</code> for full type name
+ or <code class="computeroutput">mpl::false_</code> for base type name and the second argument must be
+ a specialization of the <code class="computeroutput">::std::char_traits</code> template with <code class="computeroutput">char</code>
+ for <code class="computeroutput">::std::string</code> return value type or <code class="computeroutput">wchar_t</code> for
+ <code class="computeroutput">::std::wstring</code> return value type.
+ </p>
+<a name="mirror.reference.sample.meta_namespace.usage03"></a><pre class="programlisting">
+#include &lt;iostream&gt;
+#include &lt;boost/mirror/meta_namespace.hpp&gt;
+
+
+template &lt; typename CharT, typename NsPlaceholder &gt;
+::std::basic_ostream&lt; CharT, ::std::char_traits&lt; CharT &gt; &gt;&amp;
+operator &lt;&lt; (
+ ::std::basic_ostream&lt; CharT, ::std::char_traits&lt; CharT &gt; &gt;&amp; _s,
+ ::boost::mirror::meta_namespace&lt; NsPlaceholder &gt; _mn
+)
+{
+ return _s &lt;&lt;_mn.get_name(
+ ::boost::mpl::true_(),
+ ::std::char_traits&lt; CharT &gt;()
+ );
+}
+
+
+int main(void)
+{
+ using namespace ::std;
+ //
+ typedef BOOST_MIRRORED_NAMESPACE(::boost::mirror) meta_Ns;
+ meta_Ns mns;
+ //
+ cout &lt;&lt; mns &lt;&lt; endl;
+ wcout &lt;&lt; mns &lt;&lt; endl;
+
+ return 0;
+}
+</pre>
+</div>
 </div>
 <div class="refsect2" lang="en">
-<a name="id698158"></a><h3>
-<a name="id461075-bbtypes"></a><code class="computeroutput">meta_namespace</code> public types</h3>
+<a name="id694952"></a><h3>
+<a name="id461012-bbtypes"></a><code class="computeroutput">meta_namespace</code> public types</h3>
 <div class="orderedlist"><ol type="1">
 <li>
 <p>
@@ -242,7 +292,7 @@
 </li>
 </ol></div>
 </div>
-<pre class="literallayout"><span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a name="id460952-bb"></a>base_name();</pre>
+<pre class="literallayout"><span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a name="id460888-bb"></a>base_name();</pre>
 <p>This static member function returns the base name of the
                                         namespace reflected by a <code class="computeroutput">meta_namespace</code>.
                                         For example the base namespace name "returned" by the invocation of
@@ -254,7 +304,7 @@
                                         <span class="bold"><strong>with</strong></span> the nested name specifier
                                         is needed use the <code class="computeroutput">full_name</code> member function
                                                instead.</p>
-<pre class="literallayout"><span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a name="id460910-bb"></a>full_name();</pre>
+<pre class="literallayout"><span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a name="id460846-bb"></a>full_name();</pre>
 <p>This static member function returns the full name of the
                                         namespace reflected by a <code class="computeroutput">meta_namespace</code>
                                         with the nested name specifier. For example:
@@ -281,7 +331,7 @@
 </table></div>
 <pre class="literallayout"><span class="bold"><strong>template</strong></span>&lt;<span class="bold"><strong>bool</strong></span> FullName, <span class="bold"><strong>typename</strong></span> CharT&gt;
   <span class="type"><span class="bold"><strong>const</strong></span> ::std::basic_string&lt;CharT&gt;&amp;</span>
- <a name="id460856-bb"></a>get_name(::boost::mpl::bool_&lt;FullName&gt; full, ::std::char_traits&lt;CharT&gt; cht);</pre>
+ <a name="id460792-bb"></a>get_name(::boost::mpl::bool_&lt;FullName&gt; full, ::std::char_traits&lt;CharT&gt; cht);</pre>
 <p>This static member template function returns either the base name
                                         <span class="bold"><strong>without</strong></span> the nested name specifier
                                         or the full name <span class="bold"><strong>with</strong></span> the

Modified: sandbox/mirror/doc/html/boost/mirror/meta_type.html
==============================================================================
--- sandbox/mirror/doc/html/boost/mirror/meta_type.html (original)
+++ sandbox/mirror/doc/html/boost/mirror/meta_type.html 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -44,17 +44,17 @@
 <div xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv"><pre class="synopsis"><span class="bold"><strong>template</strong></span>&lt;<span class="bold"><strong>typename</strong></span> Type&gt;
 <span class="bold"><strong>class</strong></span> <a class="link" href="meta_type.html" title="Class template meta_type">meta_type</a> {
 <span class="bold"><strong>public</strong></span>:
- <span class="emphasis"><em>// <a class="link" href="meta_type.html#id460529-bbtypes">types</a></em></span>
+ <span class="emphasis"><em>// <a class="link" href="meta_type.html#id460402-bbtypes">types</a></em></span>
   <span class="bold"><strong>typedef</strong></span> Type <a class="link" href="meta_type.html#boost.mirror.meta_type.reflected_type">reflected_type</a>;
   <span class="bold"><strong>typedef</strong></span> <span class="emphasis"><em>unspecified</em></span> <a class="link" href="meta_type.html#boost.mirror.meta_type.scope">scope</a>;
- <span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a class="link" href="meta_type.html#id460468-bb">base_name</a>();
- <span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a class="link" href="meta_type.html#id460408-bb">full_name</a>();
+ <span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a class="link" href="meta_type.html#id460341-bb">base_name</a>();
+ <span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a class="link" href="meta_type.html#id460281-bb">full_name</a>();
   <span class="bold"><strong>template</strong></span>&lt;<span class="bold"><strong>bool</strong></span> FullName, <span class="bold"><strong>typename</strong></span> CharT&gt;
     <span class="type"><span class="bold"><strong>const</strong></span> ::std::basic_string&lt;CharT&gt;&amp;</span>
- <a class="link" href="meta_type.html#id460348-bb">get_name</a>(::boost::mpl::bool_&lt;FullName&gt;, ::std::char_traits&lt;CharT&gt;);
+ <a class="link" href="meta_type.html#id460216-bb">get_name</a>(::boost::mpl::bool_&lt;FullName&gt;, ::std::char_traits&lt;CharT&gt;);
 };</pre></div>
 <div class="refsect1" lang="en">
-<a name="id698698"></a><h2>Description</h2>
+<a name="id695492"></a><h2>Description</h2>
 <p>The specializations of <code class="computeroutput">meta_type</code> can
                                 be used to get meta-information about the reflected types, some at compile-time and some at run-time.
                                 The following examples show type reflection and basic
@@ -69,6 +69,7 @@
 <dt><span class="section">Example - Basic usage</span></dt>
 <dt><span class="section">Example - Using with typeof and getting scope-related information</span></dt>
 <dt><span class="section">Example - Reflection of typedef-ined types</span></dt>
+<dt><span class="section">Example - Generic typename getter</span></dt>
 </dl></div>
 <div class="section" lang="en">
 <div class="titlepage"><div><div><h6 class="title">
@@ -235,10 +236,59 @@
 }
 </pre>
 </div>
+<div class="section" lang="en">
+<div class="titlepage"><div><div><h6 class="title">
+<a name="mirror.meta_type.reference.sample04"></a>Example - Generic typename getter</h6></div></div></div>
+<p>The <code class="computeroutput">base_name</code> and the
+ <code class="computeroutput">full_name</code> member functions
+ are convenient but not very generic. The <code class="computeroutput">get_name</code>
+ method allows to specify the character type of the returned string and
+ to specify wheter a full or just the base name should be returned, based
+ on compile time arguments.
+ </p>
+<p>The first argument must be either <code class="computeroutput">mpl::true_</code> for full type name
+ or <code class="computeroutput">mpl::false_</code> for base type name and the second argument must be
+ a specialization of the <code class="computeroutput">::std::char_traits</code> template with <code class="computeroutput">char</code>
+ for <code class="computeroutput">::std::string</code> return value type or <code class="computeroutput">wchar_t</code> for
+ <code class="computeroutput">::std::wstring</code> return value type.
+ </p>
+<a name="mirror.reference.sample.meta_type.usage04"></a><pre class="programlisting">
+#include &lt;iostream&gt;
+#include &lt;boost/mirror/meta_type.hpp&gt;
+
+
+template &lt; typename CharT, typename Type &gt;
+::std::basic_ostream&lt; CharT, ::std::char_traits&lt; CharT &gt; &gt;&amp;
+operator &lt;&lt; (
+ ::std::basic_ostream&lt; CharT, ::std::char_traits&lt; CharT &gt; &gt;&amp; _s,
+ ::boost::mirror::meta_type&lt; Type &gt; _mt
+)
+{
+ return _s &lt;&lt;_mt.get_name(
+ ::boost::mpl::true_(),
+ ::std::char_traits&lt; CharT &gt;()
+ );
+}
+
+
+int main(void)
+{
+ using namespace ::std;
+ //
+ typedef BOOST_MIRRORED_TYPEDEF(::boost::cts, bstring) meta_T;
+ meta_T mt;
+ //
+ cout &lt;&lt; mt &lt;&lt; endl;
+ wcout &lt;&lt; mt &lt;&lt; endl;
+
+ return 0;
+}
+</pre>
+</div>
 </div>
 <div class="refsect2" lang="en">
-<a name="id698836"></a><h3>
-<a name="id460529-bbtypes"></a><code class="computeroutput">meta_type</code> public types</h3>
+<a name="id695701"></a><h3>
+<a name="id460402-bbtypes"></a><code class="computeroutput">meta_type</code> public types</h3>
 <div class="orderedlist"><ol type="1">
 <li>
 <p>
@@ -257,7 +307,7 @@
 </li>
 </ol></div>
 </div>
-<pre class="literallayout"><span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a name="id460468-bb"></a>base_name();</pre>
+<pre class="literallayout"><span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a name="id460341-bb"></a>base_name();</pre>
 <p>This static member function returns the base name of the
                                         type reflected by <code class="computeroutput">meta_type</code>
                                         without the nested name specifier. For example:
@@ -287,7 +337,7 @@
                                         </p></td>
 </tr></tbody>
 </table></div>
-<pre class="literallayout"><span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a name="id460408-bb"></a>full_name();</pre>
+<pre class="literallayout"><span class="type"><span class="bold"><strong>const</strong></span> cts::bstring&amp;</span> <a name="id460281-bb"></a>full_name();</pre>
 <p>This static member function returns the full name of the
                                         type reflected by <code class="computeroutput">meta_type</code>
                                         with the nested name specifier. For example:
@@ -319,7 +369,7 @@
 </table></div>
 <pre class="literallayout"><span class="bold"><strong>template</strong></span>&lt;<span class="bold"><strong>bool</strong></span> FullName, <span class="bold"><strong>typename</strong></span> CharT&gt;
   <span class="type"><span class="bold"><strong>const</strong></span> ::std::basic_string&lt;CharT&gt;&amp;</span>
- <a name="id460348-bb"></a>get_name(::boost::mpl::bool_&lt;FullName&gt; full, ::std::char_traits&lt;CharT&gt; cht);</pre>
+ <a name="id460216-bb"></a>get_name(::boost::mpl::bool_&lt;FullName&gt; full, ::std::char_traits&lt;CharT&gt; cht);</pre>
 <p>This static member template function returns either the base name
                                         <span class="bold"><strong>without</strong></span> the nested name specifier
                                         or the full name <span class="bold"><strong>with</strong></span> the

Modified: sandbox/mirror/doc/html/char_type_switch.html
==============================================================================
--- sandbox/mirror/doc/html/char_type_switch.html (original)
+++ sandbox/mirror/doc/html/char_type_switch.html 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -33,7 +33,7 @@
 </div></div>
 <div><p class="copyright">Copyright © 2008 Matú&#353; Chochlík</p></div>
 <div><div class="legalnotice">
-<a name="id699443"></a><p>Use, modification and distribution is subject to the Boost
+<a name="id696308"></a><p>Use, modification and distribution is subject to the Boost
                         Software License, Version 1.0. (See accompanying file
                         <code class="filename">LICENSE_1_0.txt</code> or copy at http://www.boost.org/LICENSE_1_0.txt)
                         </p>

Modified: sandbox/mirror/doc/html/index.html
==============================================================================
--- sandbox/mirror/doc/html/index.html (original)
+++ sandbox/mirror/doc/html/index.html 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -21,7 +21,7 @@
 <div class="book" lang="en">
 <div class="titlepage">
 <div><div><h1 class="title">
-<a name="id596016"></a>The Mirror library documentation</h1></div></div>
+<a name="id592739"></a>The Mirror library documentation</h1></div></div>
 <hr>
 </div>
 <div class="toc">

Modified: sandbox/mirror/doc/html/mirror.html
==============================================================================
--- sandbox/mirror/doc/html/mirror.html (original)
+++ sandbox/mirror/doc/html/mirror.html 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -34,7 +34,7 @@
 </div></div>
 <div><p class="copyright">Copyright © 2008 Matú&#353; Chochlík</p></div>
 <div><div class="legalnotice">
-<a name="id697499"></a><p>Use, modification and distribution is subject to the Boost
+<a name="id694223"></a><p>Use, modification and distribution is subject to the Boost
                         Software License, Version 1.0. (See accompanying file
                         <code class="filename">LICENSE_1_0.txt</code> or copy at http://www.boost.org/LICENSE_1_0.txt)
                         </p>

Modified: sandbox/mirror/libs/mirror/doc/reference/meta_namespace.xml
==============================================================================
--- sandbox/mirror/libs/mirror/doc/reference/meta_namespace.xml (original)
+++ sandbox/mirror/libs/mirror/doc/reference/meta_namespace.xml 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -52,6 +52,23 @@
                                         </para>
                                         <xi:include href="../samples/usage_meta_namespace_02.xml"/>
                                 </section>
+ <section id="mirror.meta_namespace.reference.sample03">
+ <title>Example - Generic namespace name getter</title>
+ <para>The <code><methodname>base_name</methodname></code> and the
+ <code><methodname>full_name</methodname></code> methods
+ are convenient but not very generic. The <code><methodname>get_name</methodname></code>
+ member function allows to specify the character type of the returned string and
+ to specify wheter a full or just the base namespace name should be returned, based
+ on compile time arguments.
+ </para>
+ <para>The first argument must be either <code>mpl::true_</code> for full type name
+ or <code>mpl::false_</code> for base type name and the second argument must be
+ a specialization of the <code>::std::char_traits</code> template with <code>char</code>
+ for <code>::std::string</code> return value type or <code>wchar_t</code> for
+ <code>::std::wstring</code> return value type.
+ </para>
+ <xi:include href="../samples/usage_meta_namespace_03.xml"/>
+ </section>
                                 </section>
                         </description>
 

Modified: sandbox/mirror/libs/mirror/doc/reference/meta_type.xml
==============================================================================
--- sandbox/mirror/libs/mirror/doc/reference/meta_type.xml (original)
+++ sandbox/mirror/libs/mirror/doc/reference/meta_type.xml 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -64,6 +64,23 @@
                                         </para>
                                         <xi:include href="../samples/usage_meta_type_03.xml"/>
                                 </section>
+ <section id="mirror.meta_type.reference.sample04">
+ <title>Example - Generic typename getter</title>
+ <para>The <code><methodname>base_name</methodname></code> and the
+ <code><methodname>full_name</methodname></code> member functions
+ are convenient but not very generic. The <code><methodname>get_name</methodname></code>
+ method allows to specify the character type of the returned string and
+ to specify wheter a full or just the base name should be returned, based
+ on compile time arguments.
+ </para>
+ <para>The first argument must be either <code>mpl::true_</code> for full type name
+ or <code>mpl::false_</code> for base type name and the second argument must be
+ a specialization of the <code>::std::char_traits</code> template with <code>char</code>
+ for <code>::std::string</code> return value type or <code>wchar_t</code> for
+ <code>::std::wstring</code> return value type.
+ </para>
+ <xi:include href="../samples/usage_meta_type_04.xml"/>
+ </section>
                                 </section>
                         </description>
 

Added: sandbox/mirror/libs/mirror/doc/samples/usage_meta_namespace_03.xml
==============================================================================
--- (empty file)
+++ sandbox/mirror/libs/mirror/doc/samples/usage_meta_namespace_03.xml 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE section PUBLIC "-//Boost//DTD BoostBook XML V1.0//EN"
+ "http://www.boost.org/tools/boostbook/dtd/boostbook.dtd">
+<programlisting id="mirror.reference.sample.meta_namespace.usage03">
+#include &lt;iostream&gt;
+#include &lt;boost/mirror/meta_namespace.hpp&gt;
+
+
+template &lt; typename CharT, typename NsPlaceholder &gt;
+::std::basic_ostream&lt; CharT, ::std::char_traits&lt; CharT &gt; &gt;&amp;
+operator &lt;&lt; (
+ ::std::basic_ostream&lt; CharT, ::std::char_traits&lt; CharT &gt; &gt;&amp; _s,
+ ::boost::mirror::meta_namespace&lt; NsPlaceholder &gt; _mn
+)
+{
+ return _s &lt;&lt;_mn.get_name(
+ ::boost::mpl::true_(),
+ ::std::char_traits&lt; CharT &gt;()
+ );
+}
+
+
+int main(void)
+{
+ using namespace ::std;
+ //
+ typedef BOOST_MIRRORED_NAMESPACE(::boost::mirror) meta_Ns;
+ meta_Ns mns;
+ //
+ cout &lt;&lt; mns &lt;&lt; endl;
+ wcout &lt;&lt; mns &lt;&lt; endl;
+
+ return 0;
+}
+</programlisting>
+

Added: sandbox/mirror/libs/mirror/doc/samples/usage_meta_type_04.xml
==============================================================================
--- (empty file)
+++ sandbox/mirror/libs/mirror/doc/samples/usage_meta_type_04.xml 2008-07-16 12:28:40 EDT (Wed, 16 Jul 2008)
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE section PUBLIC "-//Boost//DTD BoostBook XML V1.0//EN"
+ "http://www.boost.org/tools/boostbook/dtd/boostbook.dtd">
+<programlisting id="mirror.reference.sample.meta_type.usage04">
+#include &lt;iostream&gt;
+#include &lt;boost/mirror/meta_type.hpp&gt;
+
+
+template &lt; typename CharT, typename Type &gt;
+::std::basic_ostream&lt; CharT, ::std::char_traits&lt; CharT &gt; &gt;&amp;
+operator &lt;&lt; (
+ ::std::basic_ostream&lt; CharT, ::std::char_traits&lt; CharT &gt; &gt;&amp; _s,
+ ::boost::mirror::meta_type&lt; Type &gt; _mt
+)
+{
+ return _s &lt;&lt;_mt.get_name(
+ ::boost::mpl::true_(),
+ ::std::char_traits&lt; CharT &gt;()
+ );
+}
+
+
+int main(void)
+{
+ using namespace ::std;
+ //
+ typedef BOOST_MIRRORED_TYPEDEF(::boost::cts, bstring) meta_T;
+ meta_T mt;
+ //
+ cout &lt;&lt; mt &lt;&lt; endl;
+ wcout &lt;&lt; mt &lt;&lt; endl;
+
+ return 0;
+}
+</programlisting>
+


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk