Boost logo

Boost-Commit :

From: chris_at_[hidden]
Date: 2008-09-03 05:08:05


Author: chris_kohlhoff
Date: 2008-09-03 05:08:04 EDT (Wed, 03 Sep 2008)
New Revision: 48561
URL: http://svn.boost.org/trac/boost/changeset/48561

Log:
Update completion_condition documentation to match new signature.

Text files modified:
   trunk/boost/asio/read.hpp | 110 +++++++++++++++++++------------------
   trunk/boost/asio/read_at.hpp | 78 +++++++++++++-------------
   trunk/boost/asio/write.hpp | 116 ++++++++++++++++++++--------------------
   trunk/boost/asio/write_at.hpp | 70 ++++++++++++------------
   4 files changed, 189 insertions(+), 185 deletions(-)

Modified: trunk/boost/asio/read.hpp
==============================================================================
--- trunk/boost/asio/read.hpp (original)
+++ trunk/boost/asio/read.hpp 2008-09-03 05:08:04 EDT (Wed, 03 Sep 2008)
@@ -46,7 +46,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -85,7 +85,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -98,15 +98,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest read_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest read_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the stream's read_some function are required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the stream's read_some function.
  *
  * @returns The number of bytes transferred.
  *
@@ -135,7 +136,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -148,15 +149,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest read_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest read_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the stream's read_some function are required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the stream's read_some function.
  *
  * @param ec Set to indicate what error occurred, if any.
  *
@@ -175,7 +177,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -202,7 +204,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -213,15 +215,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest read_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest read_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the stream's read_some function are required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the stream's read_some function.
  *
  * @returns The number of bytes transferred.
  *
@@ -239,7 +242,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -250,15 +253,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest read_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest read_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the stream's read_some function are required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the stream's read_some function.
  *
  * @param ec Set to indicate what error occurred, if any.
  *
@@ -292,7 +296,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * async_read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -366,16 +370,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest read_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest async_read_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the stream's async_read_some function are
- * required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the stream's async_read_some function.
  *
  * @param handler The handler to be called when the read operation completes.
  * Copies will be made of the handler as required. The function signature of the
@@ -419,7 +423,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * async_read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -466,7 +470,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * async_read_some function.
  *
  * @param s The stream from which the data is to be read. The type must support
@@ -479,16 +483,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest read_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest async_read_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the stream's async_read_some function are
- * required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the stream's async_read_some function.
  *
  * @param handler The handler to be called when the read operation completes.
  * Copies will be made of the handler as required. The function signature of the

Modified: trunk/boost/asio/read_at.hpp
==============================================================================
--- trunk/boost/asio/read_at.hpp (original)
+++ trunk/boost/asio/read_at.hpp 2008-09-03 05:08:04 EDT (Wed, 03 Sep 2008)
@@ -49,7 +49,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -93,7 +93,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -108,16 +108,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
+ * @code std::size_t completion_condition(
  * // Result of latest read_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the device's read_some_at function are
- * required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the device's read_some_at function.
  *
  * @returns The number of bytes transferred.
  *
@@ -149,7 +149,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -164,16 +164,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest read_some_at
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest read_some_at operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the device's read_some_at function are
- * required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the device's read_some_at function.
  *
  * @param ec Set to indicate what error occurred, if any.
  *
@@ -195,7 +195,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -227,7 +227,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -240,16 +240,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
+ * @code std::size_t completion_condition(
  * // Result of latest read_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the device's read_some_at function are
- * required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the device's read_some_at function.
  *
  * @returns The number of bytes transferred.
  *
@@ -270,7 +270,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -283,16 +283,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
+ * @code std::size_t completion_condition(
  * // Result of latest read_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the device's read_some_at function are
- * required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the device's read_some_at function.
  *
  * @param ec Set to indicate what error occurred, if any.
  *
@@ -327,7 +327,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * async_read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -405,16 +405,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * // Result of latest read_some_at operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest async_read_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the device's async_read_some_at function are
- * required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the device's async_read_some_at function.
  *
  * @param handler The handler to be called when the read operation completes.
  * Copies will be made of the handler as required. The function signature of the
@@ -459,7 +459,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * async_read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -509,7 +509,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * async_read_some_at function.
  *
  * @param d The device from which the data is to be read. The type must support
@@ -524,16 +524,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the read operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * // Result of latest read_some_at operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest async_read_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the read operation is complete. False
- * indicates that further calls to the device's async_read_some_at function are
- * required.
+ * A return value of 0 indicates that the read operation is complete. A non-zero
+ * return value indicates the maximum number of bytes to be read on the next
+ * call to the device's async_read_some_at function.
  *
  * @param handler The handler to be called when the read operation completes.
  * Copies will be made of the handler as required. The function signature of the

Modified: trunk/boost/asio/write.hpp
==============================================================================
--- trunk/boost/asio/write.hpp (original)
+++ trunk/boost/asio/write.hpp 2008-09-03 05:08:04 EDT (Wed, 03 Sep 2008)
@@ -45,7 +45,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -84,7 +84,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -97,16 +97,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest write_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest write_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the stream's write_some function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the stream's write_some function.
  *
  * @returns The number of bytes transferred.
  *
@@ -135,7 +135,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -148,16 +148,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest write_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest write_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the stream's write_some function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the stream's write_some function.
  *
  * @param ec Set to indicate what error occurred, if any.
  *
@@ -178,7 +178,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -207,7 +207,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -218,16 +218,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest write_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest write_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the stream's write_some function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the stream's write_some function.
  *
  * @returns The number of bytes transferred.
  *
@@ -247,7 +247,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -258,16 +258,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest write_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest write_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the stream's write_some function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the stream's write_some function.
  *
  * @param ec Set to indicate what error occurred, if any.
  *
@@ -301,7 +301,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * async_write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -355,7 +355,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * async_write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -369,16 +369,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest write_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest async_write_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the stream's async_write_some function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the stream's async_write_some function.
  *
  * @param handler The handler to be called when the write operation completes.
  * Copies will be made of the handler as required. The function signature of the
@@ -423,7 +423,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * async_write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -465,7 +465,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the stream's
+ * This operation is implemented in terms of zero or more calls to the stream's
  * async_write_some function.
  *
  * @param s The stream to which the data is to be written. The type must support
@@ -478,16 +478,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * const boost::system::error_code& error, // Result of latest write_some
- * // operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest async_write_some operation.
+ * const boost::system::error_code& error,
  *
- * std::size_t bytes_transferred // Number of bytes transferred
- * // so far.
+ * // Number of bytes transferred so far.
+ * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the stream's async_write_some function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the stream's async_write_some function.
  *
  * @param handler The handler to be called when the write operation completes.
  * Copies will be made of the handler as required. The function signature of the

Modified: trunk/boost/asio/write_at.hpp
==============================================================================
--- trunk/boost/asio/write_at.hpp (original)
+++ trunk/boost/asio/write_at.hpp 2008-09-03 05:08:04 EDT (Wed, 03 Sep 2008)
@@ -47,7 +47,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -90,7 +90,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -105,16 +105,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
+ * @code std::size_t completion_condition(
  * // Result of latest write_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the device's write_some_at function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the device's write_some_at function.
  *
  * @returns The number of bytes transferred.
  *
@@ -145,7 +145,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -160,16 +160,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
+ * @code std::size_t completion_condition(
  * // Result of latest write_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the device's write_some_at function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the device's write_some_at function.
  *
  * @param ec Set to indicate what error occurred, if any.
  *
@@ -192,7 +192,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -225,7 +225,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -238,16 +238,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
+ * @code std::size_t completion_condition(
  * // Result of latest write_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the device's write_some_at function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the device's write_some_at function.
  *
  * @returns The number of bytes transferred.
  *
@@ -268,7 +268,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -281,16 +281,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
+ * @code std::size_t completion_condition(
  * // Result of latest write_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the device's write_some_at function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the device's write_some_at function.
  *
  * @param ec Set to indicate what error occurred, if any.
  *
@@ -325,7 +325,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * async_write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -381,7 +381,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * async_write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -397,16 +397,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
- * // Result of latest write_some_at operation.
+ * @code std::size_t completion_condition(
+ * // Result of latest async_write_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the device's async_write_some_at function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the device's async_write_some_at function.
  *
  * @param handler The handler to be called when the write operation completes.
  * Copies will be made of the handler as required. The function signature of the
@@ -452,7 +452,7 @@
  *
  * @li An error occurred.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * async_write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -497,7 +497,7 @@
  *
  * @li The completion_condition function object returns true.
  *
- * This operation is implemented in terms of one or more calls to the device's
+ * This operation is implemented in terms of zero or more calls to the device's
  * async_write_some_at function.
  *
  * @param d The device to which the data is to be written. The type must support
@@ -512,16 +512,16 @@
  * @param completion_condition The function object to be called to determine
  * whether the write operation is complete. The signature of the function object
  * must be:
- * @code bool completion_condition(
+ * @code std::size_t completion_condition(
  * // Result of latest async_write_some_at operation.
  * const boost::system::error_code& error,
  *
  * // Number of bytes transferred so far.
  * std::size_t bytes_transferred
  * ); @endcode
- * A return value of true indicates that the write operation is complete. False
- * indicates that further calls to the device's async_write_some_at function are
- * required.
+ * A return value of 0 indicates that the write operation is complete. A
+ * non-zero return value indicates the maximum number of bytes to be written on
+ * the next call to the device's async_write_some_at function.
  *
  * @param handler The handler to be called when the write operation completes.
  * Copies will be made of the handler as required. The function signature of the


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