|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r49291 - trunk/libs/system/doc
From: bdawes_at_[hidden]
Date: 2008-10-12 09:27:59
Author: bemandawes
Date: 2008-10-12 09:27:59 EDT (Sun, 12 Oct 2008)
New Revision: 49291
URL: http://svn.boost.org/trac/boost/changeset/49291
Log:
System: Upgrade docs to reflect N2798 (and thus CD1), fix ticket #2125, and provide a table of deprecated names and their replacements.
Text files modified:
trunk/libs/system/doc/reference.html | 90 ++++++++++++++++++++++++++++-----------
1 files changed, 65 insertions(+), 25 deletions(-)
Modified: trunk/libs/system/doc/reference.html
==============================================================================
--- trunk/libs/system/doc/reference.html (original)
+++ trunk/libs/system/doc/reference.html 2008-10-12 09:27:59 EDT (Sun, 12 Oct 2008)
@@ -39,6 +39,7 @@
<td width="100%" bgcolor="#E8F5FF">
<a href="#Introduction">Introduction</a><br>
<a href="#Macros">Macros</a><br>
+ Deprecated names<br>
<a href="#Header-error_code">Header <boost/system/error_code.hpp></a><br>
<a href="#Class-error_category">Class <code>error_category</code></a><br>
Class error_category
synopsis<br>
@@ -116,6 +117,45 @@
<td valign="top">Deprecated features are excluded.</td>
</tr>
</table>
+<h2><a name="Deprecated-names">Deprecated names</a></h2>
+<p>In the process of adding Boost.System to C++0x standard library, some of the
+names are being changed. To ease transition, Boost.System deprecates the old
+names, but continues to provide them unless macro <code>BOOST_SYSTEM_NO_DEPRECATED</code>
+is defined.</p>
+<table border="1" cellpadding="5" cellspacing="1" style="border-collapse: collapse" bordercolor="#111111">
+ <tr>
+ <td><b><i>Old name, now deprecated</i></b></td>
+ <td><b><i>New name</i></b></td>
+ </tr>
+ <tr>
+ <td><code>namespace posix</code></td>
+ <td><code>namespace errc</code></td>
+ </tr>
+ <tr>
+ <td><code>namespace posix_error</code></td>
+ <td><code>namespace errc</code></td>
+ </tr>
+ <tr>
+ <td><code>enum posix_errno</code></td>
+ <td><code>enum errc_t</code></td>
+ </tr>
+ <tr>
+ <td><code>get_posix_category()</code></td>
+ <td><code>get_generic_category()</code></td>
+ </tr>
+ <tr>
+ <td><code>posix_category</code></td>
+ <td><code>generic_category</code></td>
+ </tr>
+ <tr>
+ <td><code>errno_ecat</code></td>
+ <td><code>generic_category</code></td>
+ </tr>
+ <tr>
+ <td><code>native_ecat</code></td>
+ <td><code>system_category</code></td>
+ </tr>
+</table>
<h2><a name="Header-error_code">Header <boost/system/error_code.hpp></a></h2>
<h3><boost/system/error_code.hpp> synopsis</h3>
<blockquote>
@@ -286,7 +326,7 @@
virtual ~error_category();
virtual const char * name() const = 0;
- virtual string message( error_code::value_type ev ) const = 0;
+ virtual string message( int ev ) const = 0;
virtual error_condition default_error_condition( int ev ) const;
virtual bool equivalent( int code, const error_condition & condition ) const;
virtual bool equivalent( const error_code & code, int condition ) const;
@@ -312,7 +352,7 @@
<p><i>Returns: </i>a string naming the error category.</p>
<p><i>Throws:</i> Nothing.</p>
</blockquote>
-<pre>virtual string message( error_code::value_type ev ) const=0;</pre>
+<pre>virtual string message( int ev ) const=0;</pre>
<blockquote>
<p><i>Returns:</i> A string that describes the error denoted by
<code>ev</code>.</p>
@@ -399,7 +439,7 @@
error_code();
error_code( val, const error_category & cat );
template <class <code>ErrorCodeEnum</code>>
- error_code(<code> errorCodeEnum</code> e,
+ error_code(<code> ErrorCodeEnum</code> e,
typename enable_if<is_error_code_enum<<code>ErrorCodeEnum</code>> >::type* = 0);
// modifiers:
@@ -418,7 +458,7 @@
private:
int val_; // <i>exposition only</i>
- const error_category & cat_; // <i>exposition only</i>
+ const error_category * cat_; // <i>exposition only</i>
};
}
}</pre>
@@ -449,7 +489,7 @@
error_code</code> modifiers</a></h3>
<pre>void assign( int val, const error_category & cat );</pre>
<blockquote>
- <p><i>Postconditions:</i> <code>val_ == val && cat_ == cat</code>.</p>
+ <p><i>Postconditions:</i> <code>val_ == val && cat_ == &cat</code>.</p>
<p><i>Throws:</i> Nothing.</p>
</blockquote>
<pre>template<typename <code>ErrorCodeEnum</code>>
@@ -470,9 +510,9 @@
<p><i>Returns:</i> <code>val_</code>.</p>
<p><i>Throws:</i> Nothing.</p>
</blockquote>
- <p><code>error_category category() const;</code></p>
+ <p><code>const error_category & category() const;</code></p>
<blockquote>
-<p><i>Returns:</i> <code>cat_</code>.</p>
+<p><i>Returns:</i> <code>*cat_</code>.</p>
<p><i>Throws:</i> Nothing.</p>
</blockquote>
<pre>error_condition default_error_condition() const;</pre>
@@ -487,7 +527,7 @@
</blockquote>
<p><code>operator <i>unspecified-bool-type</i>() const;</code></p>
<blockquote>
-<p><i>Returns:</i> if <code>value() != value_type()</code>, returns a value that will evaluate
+<p><i>Returns:</i> if <code>value() != 0</code>, returns a value that will evaluate
<code>true</code> in a boolean context; otherwise, returns a value that will
evaluate <code>false</code> in a boolean context. The value type returned shall
not be convertible to <code>int</code>.</p>
@@ -534,8 +574,8 @@
operator unspecified-bool-type () const;
private:
- int val_; // <i>exposition only</i>
- const error_category & cat_; // <i>exposition only</i>
+ int val_; // <i>exposition only</i>
+ const error_category * cat_; // <i>exposition only</i>
};
}
}</pre>
@@ -545,13 +585,13 @@
<pre>error_condition(); </pre>
<blockquote>
<p><i>Effects:</i> Constructs an object of type <code>error_condition</code>.</p>
- <p><i>Postconditions:</i> <code>val_ == 0 and cat_ == generic_category</code>.</p>
+ <p><i>Postconditions:</i> <code>val_ == 0 and cat_ == &generic_category</code>.</p>
<p><i>Throws:</i> Nothing.</p>
</blockquote>
-<pre>error_condition( value_type val, const error_category & cat );</pre>
+<pre>error_condition( int val, const error_category & cat );</pre>
<blockquote>
<p><i>Effects: </i>Constructs an object of type error_condition.</p>
- <p><i>Postconditions:</i> <code>val_ == val and cat_ == cat</code>.</p>
+ <p><i>Postconditions:</i> <code>val_ == val and cat_ == &cat</code>.</p>
<p><i>Throws:</i> Nothing.</p>
</blockquote>
<pre>template <class ErrorConditionEnum>
@@ -564,9 +604,9 @@
</blockquote>
<h3><a name="Class-error_condition-modifiers">Class <code>error_condition</code>
modifiers</a></h3>
-<pre>void assign( value_type val, const error_category & cat ); </pre>
+<pre>void assign( int val, const error_category & cat ); </pre>
<blockquote>
- <p><i>Postconditions:</i> <code>val_ == val and cat_ == cat</code>. </p>
+ <p><i>Postconditions:</i> <code>val_ == val and cat_ == &cat</code>. </p>
<p><i>Throws:</i> Nothing.</p>
</blockquote>
<pre>template<typename ErrorConditionEnum>
@@ -582,14 +622,14 @@
</blockquote>
<h3><a name="Class-error_condition-observers">Class <code>error_condition</code>
observers</a></h3>
-<pre>value_type value() const;</pre>
+<pre>int value() const;</pre>
<blockquote>
<p><i>Returns:</i> <code>val_</code>.</p>
<p><i>Throws:</i> Nothing</p>
</blockquote>
<pre>const error_category & category() const;</pre>
<blockquote>
- <p><i>Returns:</i> <code>cat_</code>.</p>
+ <p><i>Returns:</i> <code>*cat_</code>.</p>
<p>Throws: Nothing.</p>
</blockquote>
<pre>string message() const;</pre>
@@ -694,7 +734,7 @@
</blockquote>
<pre>error_condition make_error_condition( errc::errc_t e );</pre>
<blockquote>
- <p><i>Returns:</i> <code>error_condition( e, generic_category)</code>.</p>
+ <p><i>Returns:</i> <code>error_condition( static_cast<int>( e ), generic_category)</code>.</p>
</blockquote>
<pre>template <class charT, class traits>
@@ -727,11 +767,11 @@
system_error( error_code ec );
system_error( error_code ec, const char * what_arg );
system_error( error_code ec, const std::string & what_arg );
- system_error( error_code::value_type ev, const error_category & ecat,
+ system_error( int ev, const error_category & ecat,
const char * what_arg );
- system_error( error_code::value_type ev, const error_category & ecat,
+ system_error( int ev, const error_category & ecat,
const std::string & what_arg );
- system_error( error_code::value_type ev, const error_category & ecat);
+ system_error( int ev, const error_category & ecat);
const error_code & code() const throw();
const char * what() const throw();
@@ -757,21 +797,21 @@
<p><i>Postcondition:</i> <code>code() == ec <br>
&& std::strcmp( this->runtime_error::what(), what_arg.c_str() ) == 0</code></p>
</blockquote>
-<pre>system_error( error_code::value_type ev, const error_category & ecat,
+<pre>system_error( int ev, const error_category & ecat,
const char * what_arg );</pre>
<blockquote>
<p><i>Effects:</i> Constructs an object of class <code>system_error</code>.</p>
<p><i>Postcondition:</i> <code>code() == error_code( ev, ecat )<br>
&& std::strcmp( this->runtime_error::what(), what_arg ) == 0</code></p>
</blockquote>
-<pre>system_error( error_code::value_type ev, const error_category & ecat,
+<pre>system_error( int ev, const error_category & ecat,
const std::string & what_arg );</pre>
<blockquote>
<p><i>Effects:</i> Constructs an object of class <code>system_error</code>.</p>
<p><i>Postcondition:</i> <code>code() == error_code( ev, ecat )<br>
&& std::strcmp( this->runtime_error::what(), what_arg.c_str() ) == 0</code></p>
</blockquote>
-<pre>system_error( error_code::value_type ev, const error_category & ecat );</pre>
+<pre>system_error( int ev, const error_category & ecat );</pre>
<blockquote>
<p><i>Effects:</i> Constructs an object of class <code>system_error</code>.</p>
<p><i>Postcondition:</i> <code>code() == error_code( ev, ecat )<br>
@@ -791,7 +831,7 @@
<hr>
<p>Revised
-<!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%B %d, %Y" startspan -->October 08, 2008<!--webbot bot="Timestamp" endspan i-checksum="30989" --> </font>
+<!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%B %d, %Y" startspan -->October 11, 2008<!--webbot bot="Timestamp" endspan i-checksum="30976" --> </font>
</p>
<p>© Copyright Beman Dawes, 2006, 2007, 2008</p>
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