[DEV] add v1.76.0

This commit is contained in:
2021-10-05 21:37:46 +02:00
parent a97e9ae7d4
commit d0115b733d
45133 changed files with 4744437 additions and 1026325 deletions

View File

@@ -0,0 +1,55 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::~basic_stream_socket</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="write_some/overload2.html" title="basic_stream_socket::write_some (2 of 2 overloads)">
<link rel="next" href="../basic_stream_socket__rebind_executor.html" title="basic_stream_socket::rebind_executor">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="write_some/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../basic_stream_socket__rebind_executor.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket._basic_stream_socket"></a><a class="link" href="_basic_stream_socket.html" title="basic_stream_socket::~basic_stream_socket">basic_stream_socket::~basic_stream_socket</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket._basic_stream_socket"></a>
Destroys
the socket.
</p>
<pre class="programlisting">~basic_stream_socket();
</pre>
<p>
This function destroys the socket, cancelling any outstanding asynchronous
operations associated with the socket as if by calling <code class="computeroutput">cancel</code>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="write_some/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../basic_stream_socket__rebind_executor.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,60 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::assign</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="next" href="assign/overload1.html" title="basic_stream_socket::assign (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="assign/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.assign"></a><a class="link" href="assign.html" title="basic_stream_socket::assign">basic_stream_socket::assign</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.assign"></a>
Assign
an existing native socket to the socket.
</p>
<pre class="programlisting">void <a class="link" href="assign/overload1.html" title="basic_stream_socket::assign (1 of 2 overloads)">assign</a>(
const protocol_type &amp; protocol,
const native_handle_type &amp; native_socket);
<span class="emphasis"><em>» <a class="link" href="assign/overload1.html" title="basic_stream_socket::assign (1 of 2 overloads)">more...</a></em></span>
void <a class="link" href="assign/overload2.html" title="basic_stream_socket::assign (2 of 2 overloads)">assign</a>(
const protocol_type &amp; protocol,
const native_handle_type &amp; native_socket,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="assign/overload2.html" title="basic_stream_socket::assign (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="assign/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,55 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::assign (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../assign.html" title="basic_stream_socket::assign">
<link rel="prev" href="../assign.html" title="basic_stream_socket::assign">
<link rel="next" href="overload2.html" title="basic_stream_socket::assign (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../assign.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../assign.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.assign.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::assign (1 of 2 overloads)">basic_stream_socket::assign
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Assign an existing native socket to the socket.
</p>
<pre class="programlisting">void assign(
const protocol_type &amp; protocol,
const native_handle_type &amp; native_socket);
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../assign.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../assign.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,56 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::assign (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../assign.html" title="basic_stream_socket::assign">
<link rel="prev" href="overload1.html" title="basic_stream_socket::assign (1 of 2 overloads)">
<link rel="next" href="../async_connect.html" title="basic_stream_socket::async_connect">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../assign.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../async_connect.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.assign.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::assign (2 of 2 overloads)">basic_stream_socket::assign
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Assign an existing native socket to the socket.
</p>
<pre class="programlisting">void assign(
const protocol_type &amp; protocol,
const native_handle_type &amp; native_socket,
boost::system::error_code &amp; ec);
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../assign.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../async_connect.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,118 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_connect</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="assign/overload2.html" title="basic_stream_socket::assign (2 of 2 overloads)">
<link rel="next" href="async_read_some.html" title="basic_stream_socket::async_read_some">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="assign/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_read_some.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_connect"></a><a class="link" href="async_connect.html" title="basic_stream_socket::async_connect">basic_stream_socket::async_connect</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.async_connect"></a>
Start
an asynchronous connect.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../ConnectHandler.html" title="Connect handler requirements">ConnectHandler</a> = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> async_connect(
const endpoint_type &amp; peer_endpoint,
ConnectHandler &amp;&amp; handler = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
</pre>
<p>
This function is used to asynchronously connect a socket to the specified
remote endpoint. The function call always returns immediately.
</p>
<p>
The socket is automatically opened if it is not already open. If the connect
fails, and the socket was automatically opened, the socket is not returned
to the closed state.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_connect.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_connect.parameters"></a></span><a class="link" href="async_connect.html#boost_asio.reference.basic_stream_socket.async_connect.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">peer_endpoint</span></dt>
<dd><p>
The remote endpoint to which the socket will be connected. Copies
will be made of the endpoint object as required.
</p></dd>
<dt><span class="term">handler</span></dt>
<dd>
<p>
The handler to be called when the connection operation completes.
Copies will be made of the handler as required. The function signature
of the handler must be:
</p>
<pre class="programlisting">void handler(
const boost::system::error_code&amp; error // Result of operation
);
</pre>
<p>
Regardless of whether the asynchronous operation completes immediately
or not, the handler will not be invoked from within this function.
On immediate completion, invocation of the handler will be performed
in a manner equivalent to using <a class="link" href="../post.html" title="post"><code class="computeroutput">post</code></a>.
</p>
</dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_connect.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_connect.example"></a></span><a class="link" href="async_connect.html#boost_asio.reference.basic_stream_socket.async_connect.example">Example</a>
</h6>
<pre class="programlisting">void connect_handler(const boost::system::error_code&amp; error)
{
if (!error)
{
// Connect succeeded.
}
}
...
boost::asio::ip::tcp::socket socket(my_context);
boost::asio::ip::tcp::endpoint endpoint(
boost::asio::ip::address::from_string("1.2.3.4"), 12345);
socket.async_connect(endpoint, connect_handler);
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="assign/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_read_some.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,120 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_read_some</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="async_connect.html" title="basic_stream_socket::async_connect">
<link rel="next" href="async_receive.html" title="basic_stream_socket::async_receive">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_connect.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_receive.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_read_some"></a><a class="link" href="async_read_some.html" title="basic_stream_socket::async_read_some">basic_stream_socket::async_read_some</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.async_read_some"></a>
Start
an asynchronous read.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>,
typename <a class="link" href="../ReadHandler.html" title="Read handler requirements">ReadHandler</a> = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> async_read_some(
const MutableBufferSequence &amp; buffers,
ReadHandler &amp;&amp; handler = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
</pre>
<p>
This function is used to asynchronously read data from the stream socket.
The function call always returns immediately.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_read_some.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_read_some.parameters"></a></span><a class="link" href="async_read_some.html#boost_asio.reference.basic_stream_socket.async_read_some.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more buffers into which the data will be read. Although the
buffers object may be copied as necessary, ownership of the underlying
memory blocks is retained by the caller, which must guarantee that
they remain valid until the handler is called.
</p></dd>
<dt><span class="term">handler</span></dt>
<dd>
<p>
The handler to be called when the read operation completes. Copies
will be made of the handler as required. The function signature of
the handler must be:
</p>
<pre class="programlisting">void handler(
const boost::system::error_code&amp; error, // Result of operation.
std::size_t bytes_transferred // Number of bytes read.
);
</pre>
<p>
Regardless of whether the asynchronous operation completes immediately
or not, the handler will not be invoked from within this function.
On immediate completion, invocation of the handler will be performed
in a manner equivalent to using <a class="link" href="../post.html" title="post"><code class="computeroutput">post</code></a>.
</p>
</dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_read_some.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_read_some.remarks"></a></span><a class="link" href="async_read_some.html#boost_asio.reference.basic_stream_socket.async_read_some.remarks">Remarks</a>
</h6>
<p>
The read operation may not read all of the requested number of bytes. Consider
using the <a class="link" href="../async_read.html" title="async_read"><code class="computeroutput">async_read</code></a>
function if you need to ensure that the requested amount of data is read
before the asynchronous operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_read_some.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_read_some.example"></a></span><a class="link" href="async_read_some.html#boost_asio.reference.basic_stream_socket.async_read_some.example">Example</a>
</h6>
<p>
To read into a single data buffer use the <a class="link" href="../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.async_read_some(boost::asio::buffer(data, size), handler);
</pre>
<p>
See the <a class="link" href="../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on reading into multiple buffers in one go,
and how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_connect.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_receive.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,66 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_receive</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="async_read_some.html" title="basic_stream_socket::async_read_some">
<link rel="next" href="async_receive/overload1.html" title="basic_stream_socket::async_receive (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_read_some.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_receive/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_receive"></a><a class="link" href="async_receive.html" title="basic_stream_socket::async_receive">basic_stream_socket::async_receive</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.async_receive"></a>
Start
an asynchronous receive.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>,
typename <a class="link" href="../ReadHandler.html" title="Read handler requirements">ReadHandler</a> = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> <a class="link" href="async_receive/overload1.html" title="basic_stream_socket::async_receive (1 of 2 overloads)">async_receive</a>(
const MutableBufferSequence &amp; buffers,
ReadHandler &amp;&amp; handler = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
<span class="emphasis"><em>» <a class="link" href="async_receive/overload1.html" title="basic_stream_socket::async_receive (1 of 2 overloads)">more...</a></em></span>
template&lt;
typename <a class="link" href="../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>,
typename <a class="link" href="../ReadHandler.html" title="Read handler requirements">ReadHandler</a> = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> <a class="link" href="async_receive/overload2.html" title="basic_stream_socket::async_receive (2 of 2 overloads)">async_receive</a>(
const MutableBufferSequence &amp; buffers,
socket_base::message_flags flags,
ReadHandler &amp;&amp; handler = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
<span class="emphasis"><em>» <a class="link" href="async_receive/overload2.html" title="basic_stream_socket::async_receive (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_read_some.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_receive/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,119 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_receive (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../async_receive.html" title="basic_stream_socket::async_receive">
<link rel="prev" href="../async_receive.html" title="basic_stream_socket::async_receive">
<link rel="next" href="overload2.html" title="basic_stream_socket::async_receive (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../async_receive.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../async_receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_receive.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::async_receive (1 of 2 overloads)">basic_stream_socket::async_receive
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
Start an asynchronous receive.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>,
typename <a class="link" href="../../ReadHandler.html" title="Read handler requirements">ReadHandler</a> = <a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> async_receive(
const MutableBufferSequence &amp; buffers,
ReadHandler &amp;&amp; handler = <a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
</pre>
<p>
This function is used to asynchronously receive data from the stream
socket. The function call always returns immediately.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_receive.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_receive.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.async_receive.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more buffers into which the data will be received. Although
the buffers object may be copied as necessary, ownership of the
underlying memory blocks is retained by the caller, which must
guarantee that they remain valid until the handler is called.
</p></dd>
<dt><span class="term">handler</span></dt>
<dd>
<p>
The handler to be called when the receive operation completes.
Copies will be made of the handler as required. The function signature
of the handler must be:
</p>
<pre class="programlisting">void handler(
const boost::system::error_code&amp; error, // Result of operation.
std::size_t bytes_transferred // Number of bytes received.
);
</pre>
<p>
Regardless of whether the asynchronous operation completes immediately
or not, the handler will not be invoked from within this function.
On immediate completion, invocation of the handler will be performed
in a manner equivalent to using <a class="link" href="../../post.html" title="post"><code class="computeroutput">post</code></a>.
</p>
</dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_receive.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_receive.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.async_receive.overload1.remarks">Remarks</a>
</h6>
<p>
The receive operation may not receive all of the requested number of
bytes. Consider using the <a class="link" href="../../async_read.html" title="async_read"><code class="computeroutput">async_read</code></a>
function if you need to ensure that the requested amount of data is received
before the asynchronous operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_receive.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_receive.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.async_receive.overload1.example">Example</a>
</h6>
<p>
To receive into a single data buffer use the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.async_receive(boost::asio::buffer(data, size), handler);
</pre>
<p>
See the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on receiving into multiple buffers in one
go, and how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../async_receive.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../async_receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,124 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_receive (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../async_receive.html" title="basic_stream_socket::async_receive">
<link rel="prev" href="overload1.html" title="basic_stream_socket::async_receive (1 of 2 overloads)">
<link rel="next" href="../async_send.html" title="basic_stream_socket::async_send">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../async_receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../async_send.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_receive.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::async_receive (2 of 2 overloads)">basic_stream_socket::async_receive
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
Start an asynchronous receive.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>,
typename <a class="link" href="../../ReadHandler.html" title="Read handler requirements">ReadHandler</a> = <a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> async_receive(
const MutableBufferSequence &amp; buffers,
socket_base::message_flags flags,
ReadHandler &amp;&amp; handler = <a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
</pre>
<p>
This function is used to asynchronously receive data from the stream
socket. The function call always returns immediately.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_receive.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_receive.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.async_receive.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more buffers into which the data will be received. Although
the buffers object may be copied as necessary, ownership of the
underlying memory blocks is retained by the caller, which must
guarantee that they remain valid until the handler is called.
</p></dd>
<dt><span class="term">flags</span></dt>
<dd><p>
Flags specifying how the receive call is to be made.
</p></dd>
<dt><span class="term">handler</span></dt>
<dd>
<p>
The handler to be called when the receive operation completes.
Copies will be made of the handler as required. The function signature
of the handler must be:
</p>
<pre class="programlisting">void handler(
const boost::system::error_code&amp; error, // Result of operation.
std::size_t bytes_transferred // Number of bytes received.
);
</pre>
<p>
Regardless of whether the asynchronous operation completes immediately
or not, the handler will not be invoked from within this function.
On immediate completion, invocation of the handler will be performed
in a manner equivalent to using <a class="link" href="../../post.html" title="post"><code class="computeroutput">post</code></a>.
</p>
</dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_receive.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_receive.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.async_receive.overload2.remarks">Remarks</a>
</h6>
<p>
The receive operation may not receive all of the requested number of
bytes. Consider using the <a class="link" href="../../async_read.html" title="async_read"><code class="computeroutput">async_read</code></a>
function if you need to ensure that the requested amount of data is received
before the asynchronous operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_receive.overload2.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_receive.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.async_receive.overload2.example">Example</a>
</h6>
<p>
To receive into a single data buffer use the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.async_receive(boost::asio::buffer(data, size), 0, handler);
</pre>
<p>
See the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on receiving into multiple buffers in one
go, and how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../async_receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../async_send.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,66 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_send</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="async_receive/overload2.html" title="basic_stream_socket::async_receive (2 of 2 overloads)">
<link rel="next" href="async_send/overload1.html" title="basic_stream_socket::async_send (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_receive/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_send/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_send"></a><a class="link" href="async_send.html" title="basic_stream_socket::async_send">basic_stream_socket::async_send</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.async_send"></a>
Start
an asynchronous send.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../ConstBufferSequence.html" title="Constant buffer sequence requirements">ConstBufferSequence</a>,
typename <a class="link" href="../WriteHandler.html" title="Write handler requirements">WriteHandler</a> = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> <a class="link" href="async_send/overload1.html" title="basic_stream_socket::async_send (1 of 2 overloads)">async_send</a>(
const ConstBufferSequence &amp; buffers,
WriteHandler &amp;&amp; handler = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
<span class="emphasis"><em>» <a class="link" href="async_send/overload1.html" title="basic_stream_socket::async_send (1 of 2 overloads)">more...</a></em></span>
template&lt;
typename <a class="link" href="../ConstBufferSequence.html" title="Constant buffer sequence requirements">ConstBufferSequence</a>,
typename <a class="link" href="../WriteHandler.html" title="Write handler requirements">WriteHandler</a> = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> <a class="link" href="async_send/overload2.html" title="basic_stream_socket::async_send (2 of 2 overloads)">async_send</a>(
const ConstBufferSequence &amp; buffers,
socket_base::message_flags flags,
WriteHandler &amp;&amp; handler = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
<span class="emphasis"><em>» <a class="link" href="async_send/overload2.html" title="basic_stream_socket::async_send (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_receive/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_send/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,119 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_send (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../async_send.html" title="basic_stream_socket::async_send">
<link rel="prev" href="../async_send.html" title="basic_stream_socket::async_send">
<link rel="next" href="overload2.html" title="basic_stream_socket::async_send (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../async_send.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../async_send.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_send.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::async_send (1 of 2 overloads)">basic_stream_socket::async_send
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
Start an asynchronous send.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../ConstBufferSequence.html" title="Constant buffer sequence requirements">ConstBufferSequence</a>,
typename <a class="link" href="../../WriteHandler.html" title="Write handler requirements">WriteHandler</a> = <a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> async_send(
const ConstBufferSequence &amp; buffers,
WriteHandler &amp;&amp; handler = <a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
</pre>
<p>
This function is used to asynchronously send data on the stream socket.
The function call always returns immediately.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_send.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_send.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.async_send.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more data buffers to be sent on the socket. Although the
buffers object may be copied as necessary, ownership of the underlying
memory blocks is retained by the caller, which must guarantee that
they remain valid until the handler is called.
</p></dd>
<dt><span class="term">handler</span></dt>
<dd>
<p>
The handler to be called when the send operation completes. Copies
will be made of the handler as required. The function signature
of the handler must be:
</p>
<pre class="programlisting">void handler(
const boost::system::error_code&amp; error, // Result of operation.
std::size_t bytes_transferred // Number of bytes sent.
);
</pre>
<p>
Regardless of whether the asynchronous operation completes immediately
or not, the handler will not be invoked from within this function.
On immediate completion, invocation of the handler will be performed
in a manner equivalent to using <a class="link" href="../../post.html" title="post"><code class="computeroutput">post</code></a>.
</p>
</dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_send.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_send.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.async_send.overload1.remarks">Remarks</a>
</h6>
<p>
The send operation may not transmit all of the data to the peer. Consider
using the <a class="link" href="../../async_write.html" title="async_write"><code class="computeroutput">async_write</code></a>
function if you need to ensure that all data is written before the asynchronous
operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_send.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_send.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.async_send.overload1.example">Example</a>
</h6>
<p>
To send a single data buffer use the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.async_send(boost::asio::buffer(data, size), handler);
</pre>
<p>
See the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on sending multiple buffers in one go,
and how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../async_send.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../async_send.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,124 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_send (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../async_send.html" title="basic_stream_socket::async_send">
<link rel="prev" href="overload1.html" title="basic_stream_socket::async_send (1 of 2 overloads)">
<link rel="next" href="../async_wait.html" title="basic_stream_socket::async_wait">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../async_send.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../async_wait.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_send.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::async_send (2 of 2 overloads)">basic_stream_socket::async_send
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
Start an asynchronous send.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../ConstBufferSequence.html" title="Constant buffer sequence requirements">ConstBufferSequence</a>,
typename <a class="link" href="../../WriteHandler.html" title="Write handler requirements">WriteHandler</a> = <a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> async_send(
const ConstBufferSequence &amp; buffers,
socket_base::message_flags flags,
WriteHandler &amp;&amp; handler = <a class="link" href="../../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
</pre>
<p>
This function is used to asynchronously send data on the stream socket.
The function call always returns immediately.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_send.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_send.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.async_send.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more data buffers to be sent on the socket. Although the
buffers object may be copied as necessary, ownership of the underlying
memory blocks is retained by the caller, which must guarantee that
they remain valid until the handler is called.
</p></dd>
<dt><span class="term">flags</span></dt>
<dd><p>
Flags specifying how the send call is to be made.
</p></dd>
<dt><span class="term">handler</span></dt>
<dd>
<p>
The handler to be called when the send operation completes. Copies
will be made of the handler as required. The function signature
of the handler must be:
</p>
<pre class="programlisting">void handler(
const boost::system::error_code&amp; error, // Result of operation.
std::size_t bytes_transferred // Number of bytes sent.
);
</pre>
<p>
Regardless of whether the asynchronous operation completes immediately
or not, the handler will not be invoked from within this function.
On immediate completion, invocation of the handler will be performed
in a manner equivalent to using <a class="link" href="../../post.html" title="post"><code class="computeroutput">post</code></a>.
</p>
</dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_send.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_send.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.async_send.overload2.remarks">Remarks</a>
</h6>
<p>
The send operation may not transmit all of the data to the peer. Consider
using the <a class="link" href="../../async_write.html" title="async_write"><code class="computeroutput">async_write</code></a>
function if you need to ensure that all data is written before the asynchronous
operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_send.overload2.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_send.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.async_send.overload2.example">Example</a>
</h6>
<p>
To send a single data buffer use the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.async_send(boost::asio::buffer(data, size), 0, handler);
</pre>
<p>
See the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on sending multiple buffers in one go,
and how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../async_send.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../async_wait.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,112 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_wait</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="async_send/overload2.html" title="basic_stream_socket::async_send (2 of 2 overloads)">
<link rel="next" href="async_write_some.html" title="basic_stream_socket::async_write_some">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_send/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_write_some.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_wait"></a><a class="link" href="async_wait.html" title="basic_stream_socket::async_wait">basic_stream_socket::async_wait</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.async_wait"></a>
Asynchronously
wait for the socket to become ready to read, ready to write, or to have
pending error conditions.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../WaitHandler.html" title="Wait handler requirements">WaitHandler</a> = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> async_wait(
wait_type w,
WaitHandler &amp;&amp; handler = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
</pre>
<p>
This function is used to perform an asynchronous wait for a socket to enter
a ready to read, write or error condition state.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_wait.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_wait.parameters"></a></span><a class="link" href="async_wait.html#boost_asio.reference.basic_stream_socket.async_wait.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">w</span></dt>
<dd><p>
Specifies the desired socket state.
</p></dd>
<dt><span class="term">handler</span></dt>
<dd>
<p>
The handler to be called when the wait operation completes. Copies
will be made of the handler as required. The function signature of
the handler must be:
</p>
<pre class="programlisting">void handler(
const boost::system::error_code&amp; error // Result of operation
);
</pre>
<p>
Regardless of whether the asynchronous operation completes immediately
or not, the handler will not be invoked from within this function.
On immediate completion, invocation of the handler will be performed
in a manner equivalent to using <a class="link" href="../post.html" title="post"><code class="computeroutput">post</code></a>.
</p>
</dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_wait.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_wait.example"></a></span><a class="link" href="async_wait.html#boost_asio.reference.basic_stream_socket.async_wait.example">Example</a>
</h6>
<pre class="programlisting">void wait_handler(const boost::system::error_code&amp; error)
{
if (!error)
{
// Wait succeeded.
}
}
...
boost::asio::ip::tcp::socket socket(my_context);
...
socket.async_wait(boost::asio::ip::tcp::socket::wait_read, wait_handler);
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_send/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="async_write_some.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,120 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::async_write_some</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="async_wait.html" title="basic_stream_socket::async_wait">
<link rel="next" href="at_mark.html" title="basic_stream_socket::at_mark">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_wait.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="at_mark.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.async_write_some"></a><a class="link" href="async_write_some.html" title="basic_stream_socket::async_write_some">basic_stream_socket::async_write_some</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.async_write_some"></a>
Start
an asynchronous write.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../ConstBufferSequence.html" title="Constant buffer sequence requirements">ConstBufferSequence</a>,
typename <a class="link" href="../WriteHandler.html" title="Write handler requirements">WriteHandler</a> = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>&gt;
<a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.automatic_deduction_of_initiating_function_return_type"><span class="emphasis"><em>DEDUCED</em></span></a> async_write_some(
const ConstBufferSequence &amp; buffers,
WriteHandler &amp;&amp; handler = <a class="link" href="../asynchronous_operations.html#boost_asio.reference.asynchronous_operations.default_completion_tokens"><span class="emphasis"><em>DEFAULT</em></span></a>);
</pre>
<p>
This function is used to asynchronously write data to the stream socket.
The function call always returns immediately.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_write_some.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_write_some.parameters"></a></span><a class="link" href="async_write_some.html#boost_asio.reference.basic_stream_socket.async_write_some.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more data buffers to be written to the socket. Although the
buffers object may be copied as necessary, ownership of the underlying
memory blocks is retained by the caller, which must guarantee that
they remain valid until the handler is called.
</p></dd>
<dt><span class="term">handler</span></dt>
<dd>
<p>
The handler to be called when the write operation completes. Copies
will be made of the handler as required. The function signature of
the handler must be:
</p>
<pre class="programlisting">void handler(
const boost::system::error_code&amp; error, // Result of operation.
std::size_t bytes_transferred // Number of bytes written.
);
</pre>
<p>
Regardless of whether the asynchronous operation completes immediately
or not, the handler will not be invoked from within this function.
On immediate completion, invocation of the handler will be performed
in a manner equivalent to using <a class="link" href="../post.html" title="post"><code class="computeroutput">post</code></a>.
</p>
</dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_write_some.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_write_some.remarks"></a></span><a class="link" href="async_write_some.html#boost_asio.reference.basic_stream_socket.async_write_some.remarks">Remarks</a>
</h6>
<p>
The write operation may not transmit all of the data to the peer. Consider
using the <a class="link" href="../async_write.html" title="async_write"><code class="computeroutput">async_write</code></a>
function if you need to ensure that all data is written before the asynchronous
operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.async_write_some.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.async_write_some.example"></a></span><a class="link" href="async_write_some.html#boost_asio.reference.basic_stream_socket.async_write_some.example">Example</a>
</h6>
<p>
To write a single data buffer use the <a class="link" href="../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.async_write_some(boost::asio::buffer(data, size), handler);
</pre>
<p>
See the <a class="link" href="../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on writing multiple buffers in one go, and
how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_wait.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="at_mark.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,56 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::at_mark</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="async_write_some.html" title="basic_stream_socket::async_write_some">
<link rel="next" href="at_mark/overload1.html" title="basic_stream_socket::at_mark (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_write_some.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="at_mark/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.at_mark"></a><a class="link" href="at_mark.html" title="basic_stream_socket::at_mark">basic_stream_socket::at_mark</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.at_mark"></a>
Determine
whether the socket is at the out-of-band data mark.
</p>
<pre class="programlisting">bool <a class="link" href="at_mark/overload1.html" title="basic_stream_socket::at_mark (1 of 2 overloads)">at_mark</a>() const;
<span class="emphasis"><em>» <a class="link" href="at_mark/overload1.html" title="basic_stream_socket::at_mark (1 of 2 overloads)">more...</a></em></span>
bool <a class="link" href="at_mark/overload2.html" title="basic_stream_socket::at_mark (2 of 2 overloads)">at_mark</a>(
boost::system::error_code &amp; ec) const;
<span class="emphasis"><em>» <a class="link" href="at_mark/overload2.html" title="basic_stream_socket::at_mark (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="async_write_some.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="at_mark/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,78 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::at_mark (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../at_mark.html" title="basic_stream_socket::at_mark">
<link rel="prev" href="../at_mark.html" title="basic_stream_socket::at_mark">
<link rel="next" href="overload2.html" title="basic_stream_socket::at_mark (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../at_mark.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../at_mark.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.at_mark.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::at_mark (1 of 2 overloads)">basic_stream_socket::at_mark
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Determine whether the socket is at the out-of-band data mark.
</p>
<pre class="programlisting">bool at_mark() const;
</pre>
<p>
This function is used to check whether the socket input is currently
positioned at the out-of-band data mark.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.at_mark.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.at_mark.overload1.return_value"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.at_mark.overload1.return_value">Return
Value</a>
</h6>
<p>
A bool indicating whether the socket is at the out-of-band data mark.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.at_mark.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.at_mark.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.at_mark.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../at_mark.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../at_mark.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,79 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::at_mark (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../at_mark.html" title="basic_stream_socket::at_mark">
<link rel="prev" href="overload1.html" title="basic_stream_socket::at_mark (1 of 2 overloads)">
<link rel="next" href="../available.html" title="basic_stream_socket::available">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../at_mark.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../available.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.at_mark.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::at_mark (2 of 2 overloads)">basic_stream_socket::at_mark
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Determine whether the socket is at the out-of-band data mark.
</p>
<pre class="programlisting">bool at_mark(
boost::system::error_code &amp; ec) const;
</pre>
<p>
This function is used to check whether the socket input is currently
positioned at the out-of-band data mark.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.at_mark.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.at_mark.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.at_mark.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.at_mark.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.at_mark.overload2.return_value"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.at_mark.overload2.return_value">Return
Value</a>
</h6>
<p>
A bool indicating whether the socket is at the out-of-band data mark.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../at_mark.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../available.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,56 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::available</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="at_mark/overload2.html" title="basic_stream_socket::at_mark (2 of 2 overloads)">
<link rel="next" href="available/overload1.html" title="basic_stream_socket::available (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="at_mark/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="available/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.available"></a><a class="link" href="available.html" title="basic_stream_socket::available">basic_stream_socket::available</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.available"></a>
Determine
the number of bytes available for reading.
</p>
<pre class="programlisting">std::size_t <a class="link" href="available/overload1.html" title="basic_stream_socket::available (1 of 2 overloads)">available</a>() const;
<span class="emphasis"><em>» <a class="link" href="available/overload1.html" title="basic_stream_socket::available (1 of 2 overloads)">more...</a></em></span>
std::size_t <a class="link" href="available/overload2.html" title="basic_stream_socket::available (2 of 2 overloads)">available</a>(
boost::system::error_code &amp; ec) const;
<span class="emphasis"><em>» <a class="link" href="available/overload2.html" title="basic_stream_socket::available (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="at_mark/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="available/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,79 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::available (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../available.html" title="basic_stream_socket::available">
<link rel="prev" href="../available.html" title="basic_stream_socket::available">
<link rel="next" href="overload2.html" title="basic_stream_socket::available (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../available.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../available.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.available.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::available (1 of 2 overloads)">basic_stream_socket::available
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Determine the number of bytes available for reading.
</p>
<pre class="programlisting">std::size_t available() const;
</pre>
<p>
This function is used to determine the number of bytes that may be read
without blocking.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.available.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.available.overload1.return_value"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.available.overload1.return_value">Return
Value</a>
</h6>
<p>
The number of bytes that may be read without blocking, or 0 if an error
occurs.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.available.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.available.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.available.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../available.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../available.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,80 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::available (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../available.html" title="basic_stream_socket::available">
<link rel="prev" href="overload1.html" title="basic_stream_socket::available (1 of 2 overloads)">
<link rel="next" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../available.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.available.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::available (2 of 2 overloads)">basic_stream_socket::available
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Determine the number of bytes available for reading.
</p>
<pre class="programlisting">std::size_t available(
boost::system::error_code &amp; ec) const;
</pre>
<p>
This function is used to determine the number of bytes that may be read
without blocking.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.available.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.available.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.available.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.available.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.available.overload2.return_value"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.available.overload2.return_value">Return
Value</a>
</h6>
<p>
The number of bytes that may be read without blocking, or 0 if an error
occurs.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../available.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,133 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="available/overload2.html" title="basic_stream_socket::available (2 of 2 overloads)">
<link rel="next" href="basic_stream_socket/overload1.html" title="basic_stream_socket::basic_stream_socket (1 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="available/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="basic_stream_socket/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket"></a><a class="link" href="basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">basic_stream_socket::basic_stream_socket</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.basic_stream_socket"></a>
Construct
a <a class="link" href="../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
without opening it.
</p>
<pre class="programlisting">explicit <a class="link" href="basic_stream_socket/overload1.html" title="basic_stream_socket::basic_stream_socket (1 of 10 overloads)">basic_stream_socket</a>(
const executor_type &amp; ex);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload1.html" title="basic_stream_socket::basic_stream_socket (1 of 10 overloads)">more...</a></em></span>
template&lt;
typename ExecutionContext&gt;
explicit <a class="link" href="basic_stream_socket/overload2.html" title="basic_stream_socket::basic_stream_socket (2 of 10 overloads)">basic_stream_socket</a>(
ExecutionContext &amp; context,
typename constraint&lt; is_convertible&lt; ExecutionContext &amp;, execution_context &amp; &gt;::value &gt;::type = 0);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload2.html" title="basic_stream_socket::basic_stream_socket (2 of 10 overloads)">more...</a></em></span>
</pre>
<p>
Construct and open a <a class="link" href="../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>.
</p>
<pre class="programlisting"><a class="link" href="basic_stream_socket/overload3.html" title="basic_stream_socket::basic_stream_socket (3 of 10 overloads)">basic_stream_socket</a>(
const executor_type &amp; ex,
const protocol_type &amp; protocol);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload3.html" title="basic_stream_socket::basic_stream_socket (3 of 10 overloads)">more...</a></em></span>
template&lt;
typename ExecutionContext&gt;
<a class="link" href="basic_stream_socket/overload4.html" title="basic_stream_socket::basic_stream_socket (4 of 10 overloads)">basic_stream_socket</a>(
ExecutionContext &amp; context,
const protocol_type &amp; protocol,
typename constraint&lt; is_convertible&lt; ExecutionContext &amp;, execution_context &amp; &gt;::value, defaulted_constraint &gt;::type = defaulted_constraint());
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload4.html" title="basic_stream_socket::basic_stream_socket (4 of 10 overloads)">more...</a></em></span>
</pre>
<p>
Construct a <a class="link" href="../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>,
opening it and binding it to the given local endpoint.
</p>
<pre class="programlisting"><a class="link" href="basic_stream_socket/overload5.html" title="basic_stream_socket::basic_stream_socket (5 of 10 overloads)">basic_stream_socket</a>(
const executor_type &amp; ex,
const endpoint_type &amp; endpoint);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload5.html" title="basic_stream_socket::basic_stream_socket (5 of 10 overloads)">more...</a></em></span>
template&lt;
typename ExecutionContext&gt;
<a class="link" href="basic_stream_socket/overload6.html" title="basic_stream_socket::basic_stream_socket (6 of 10 overloads)">basic_stream_socket</a>(
ExecutionContext &amp; context,
const endpoint_type &amp; endpoint,
typename constraint&lt; is_convertible&lt; ExecutionContext &amp;, execution_context &amp; &gt;::value &gt;::type = 0);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload6.html" title="basic_stream_socket::basic_stream_socket (6 of 10 overloads)">more...</a></em></span>
</pre>
<p>
Construct a <a class="link" href="../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
on an existing native socket.
</p>
<pre class="programlisting"><a class="link" href="basic_stream_socket/overload7.html" title="basic_stream_socket::basic_stream_socket (7 of 10 overloads)">basic_stream_socket</a>(
const executor_type &amp; ex,
const protocol_type &amp; protocol,
const native_handle_type &amp; native_socket);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload7.html" title="basic_stream_socket::basic_stream_socket (7 of 10 overloads)">more...</a></em></span>
template&lt;
typename ExecutionContext&gt;
<a class="link" href="basic_stream_socket/overload8.html" title="basic_stream_socket::basic_stream_socket (8 of 10 overloads)">basic_stream_socket</a>(
ExecutionContext &amp; context,
const protocol_type &amp; protocol,
const native_handle_type &amp; native_socket,
typename constraint&lt; is_convertible&lt; ExecutionContext &amp;, execution_context &amp; &gt;::value &gt;::type = 0);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload8.html" title="basic_stream_socket::basic_stream_socket (8 of 10 overloads)">more...</a></em></span>
</pre>
<p>
Move-construct a <a class="link" href="../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
from another.
</p>
<pre class="programlisting"><a class="link" href="basic_stream_socket/overload9.html" title="basic_stream_socket::basic_stream_socket (9 of 10 overloads)">basic_stream_socket</a>(
basic_stream_socket &amp;&amp; other);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload9.html" title="basic_stream_socket::basic_stream_socket (9 of 10 overloads)">more...</a></em></span>
</pre>
<p>
Move-construct a <a class="link" href="../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
from a socket of another protocol type.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../Protocol.html" title="Protocol requirements">Protocol1</a>,
typename <a class="link" href="../Executor1.html" title="Executor requirements">Executor1</a>&gt;
<a class="link" href="basic_stream_socket/overload10.html" title="basic_stream_socket::basic_stream_socket (10 of 10 overloads)">basic_stream_socket</a>(
basic_stream_socket&lt; Protocol1, Executor1 &gt; &amp;&amp; other,
typename constraint&lt; is_convertible&lt; Protocol1, Protocol &gt;::value &amp;&amp;is_convertible&lt; Executor1, Executor &gt;::value &gt;::type = 0);
<span class="emphasis"><em>» <a class="link" href="basic_stream_socket/overload10.html" title="basic_stream_socket::basic_stream_socket (10 of 10 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="available/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="basic_stream_socket/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,71 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (1 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="next" href="overload2.html" title="basic_stream_socket::basic_stream_socket (2 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::basic_stream_socket (1 of 10 overloads)">basic_stream_socket::basic_stream_socket
(1 of 10 overloads)</a>
</h5></div></div></div>
<p>
Construct a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
without opening it.
</p>
<pre class="programlisting">basic_stream_socket(
const executor_type &amp; ex);
</pre>
<p>
This constructor creates a stream socket without opening it. The socket
needs to be opened and then connected or accepted before data can be
sent or received on it.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ex</span></dt>
<dd><p>
The I/O executor that the socket will use, by default, to dispatch
handlers for any asynchronous operations performed on the socket.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,82 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (10 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload9.html" title="basic_stream_socket::basic_stream_socket (9 of 10 overloads)">
<link rel="next" href="../bind.html" title="basic_stream_socket::bind">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload9.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../bind.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload10"></a><a class="link" href="overload10.html" title="basic_stream_socket::basic_stream_socket (10 of 10 overloads)">basic_stream_socket::basic_stream_socket
(10 of 10 overloads)</a>
</h5></div></div></div>
<p>
Move-construct a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
from a socket of another protocol type.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../Protocol.html" title="Protocol requirements">Protocol1</a>,
typename <a class="link" href="../../Executor1.html" title="Executor requirements">Executor1</a>&gt;
basic_stream_socket(
basic_stream_socket&lt; Protocol1, Executor1 &gt; &amp;&amp; other,
typename constraint&lt; is_convertible&lt; Protocol1, Protocol &gt;::value &amp;&amp;is_convertible&lt; Executor1, Executor &gt;::value &gt;::type = 0);
</pre>
<p>
This constructor moves a stream socket from one object to another.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload10.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload10.parameters"></a></span><a class="link" href="overload10.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload10.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">other</span></dt>
<dd><p>
The other <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
object from which the move will occur.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload10.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload10.remarks"></a></span><a class="link" href="overload10.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload10.remarks">Remarks</a>
</h6>
<p>
Following the move, the moved-from object is in the same state as if
constructed using the <code class="computeroutput">basic_stream_socket(const executor_type&amp;)</code>
constructor.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload9.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../bind.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,75 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (2 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload1.html" title="basic_stream_socket::basic_stream_socket (1 of 10 overloads)">
<link rel="next" href="overload3.html" title="basic_stream_socket::basic_stream_socket (3 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload3.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::basic_stream_socket (2 of 10 overloads)">basic_stream_socket::basic_stream_socket
(2 of 10 overloads)</a>
</h5></div></div></div>
<p>
Construct a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
without opening it.
</p>
<pre class="programlisting">template&lt;
typename ExecutionContext&gt;
basic_stream_socket(
ExecutionContext &amp; context,
typename constraint&lt; is_convertible&lt; ExecutionContext &amp;, execution_context &amp; &gt;::value &gt;::type = 0);
</pre>
<p>
This constructor creates a stream socket without opening it. The socket
needs to be opened and then connected or accepted before data can be
sent or received on it.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">context</span></dt>
<dd><p>
An execution context which provides the I/O executor that the socket
will use, by default, to dispatch handlers for any asynchronous
operations performed on the socket.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload3.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,87 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (3 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload2.html" title="basic_stream_socket::basic_stream_socket (2 of 10 overloads)">
<link rel="next" href="overload4.html" title="basic_stream_socket::basic_stream_socket (4 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload2.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload4.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload3"></a><a class="link" href="overload3.html" title="basic_stream_socket::basic_stream_socket (3 of 10 overloads)">basic_stream_socket::basic_stream_socket
(3 of 10 overloads)</a>
</h5></div></div></div>
<p>
Construct and open a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>.
</p>
<pre class="programlisting">basic_stream_socket(
const executor_type &amp; ex,
const protocol_type &amp; protocol);
</pre>
<p>
This constructor creates and opens a stream socket. The socket needs
to be connected or accepted before data can be sent or received on it.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload3.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload3.parameters"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload3.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ex</span></dt>
<dd><p>
The I/O executor that the socket will use, by default, to dispatch
handlers for any asynchronous operations performed on the socket.
</p></dd>
<dt><span class="term">protocol</span></dt>
<dd><p>
An object specifying protocol parameters to be used.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload3.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload3.exceptions"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload3.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload2.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload4.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,91 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (4 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload3.html" title="basic_stream_socket::basic_stream_socket (3 of 10 overloads)">
<link rel="next" href="overload5.html" title="basic_stream_socket::basic_stream_socket (5 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload3.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload5.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload4"></a><a class="link" href="overload4.html" title="basic_stream_socket::basic_stream_socket (4 of 10 overloads)">basic_stream_socket::basic_stream_socket
(4 of 10 overloads)</a>
</h5></div></div></div>
<p>
Construct and open a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>.
</p>
<pre class="programlisting">template&lt;
typename ExecutionContext&gt;
basic_stream_socket(
ExecutionContext &amp; context,
const protocol_type &amp; protocol,
typename constraint&lt; is_convertible&lt; ExecutionContext &amp;, execution_context &amp; &gt;::value, defaulted_constraint &gt;::type = defaulted_constraint());
</pre>
<p>
This constructor creates and opens a stream socket. The socket needs
to be connected or accepted before data can be sent or received on it.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload4.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload4.parameters"></a></span><a class="link" href="overload4.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload4.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">context</span></dt>
<dd><p>
An execution context which provides the I/O executor that the socket
will use, by default, to dispatch handlers for any asynchronous
operations performed on the socket.
</p></dd>
<dt><span class="term">protocol</span></dt>
<dd><p>
An object specifying protocol parameters to be used.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload4.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload4.exceptions"></a></span><a class="link" href="overload4.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload4.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload3.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload5.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,90 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (5 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload4.html" title="basic_stream_socket::basic_stream_socket (4 of 10 overloads)">
<link rel="next" href="overload6.html" title="basic_stream_socket::basic_stream_socket (6 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload4.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload6.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload5"></a><a class="link" href="overload5.html" title="basic_stream_socket::basic_stream_socket (5 of 10 overloads)">basic_stream_socket::basic_stream_socket
(5 of 10 overloads)</a>
</h5></div></div></div>
<p>
Construct a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>,
opening it and binding it to the given local endpoint.
</p>
<pre class="programlisting">basic_stream_socket(
const executor_type &amp; ex,
const endpoint_type &amp; endpoint);
</pre>
<p>
This constructor creates a stream socket and automatically opens it bound
to the specified endpoint on the local machine. The protocol used is
the protocol associated with the given endpoint.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload5.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload5.parameters"></a></span><a class="link" href="overload5.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload5.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ex</span></dt>
<dd><p>
The I/O executor that the socket will use, by default, to dispatch
handlers for any asynchronous operations performed on the socket.
</p></dd>
<dt><span class="term">endpoint</span></dt>
<dd><p>
An endpoint on the local machine to which the stream socket will
be bound.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload5.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload5.exceptions"></a></span><a class="link" href="overload5.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload5.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload4.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload6.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,94 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (6 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload5.html" title="basic_stream_socket::basic_stream_socket (5 of 10 overloads)">
<link rel="next" href="overload7.html" title="basic_stream_socket::basic_stream_socket (7 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload5.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload7.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload6"></a><a class="link" href="overload6.html" title="basic_stream_socket::basic_stream_socket (6 of 10 overloads)">basic_stream_socket::basic_stream_socket
(6 of 10 overloads)</a>
</h5></div></div></div>
<p>
Construct a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>,
opening it and binding it to the given local endpoint.
</p>
<pre class="programlisting">template&lt;
typename ExecutionContext&gt;
basic_stream_socket(
ExecutionContext &amp; context,
const endpoint_type &amp; endpoint,
typename constraint&lt; is_convertible&lt; ExecutionContext &amp;, execution_context &amp; &gt;::value &gt;::type = 0);
</pre>
<p>
This constructor creates a stream socket and automatically opens it bound
to the specified endpoint on the local machine. The protocol used is
the protocol associated with the given endpoint.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload6.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload6.parameters"></a></span><a class="link" href="overload6.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload6.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">context</span></dt>
<dd><p>
An execution context which provides the I/O executor that the socket
will use, by default, to dispatch handlers for any asynchronous
operations performed on the socket.
</p></dd>
<dt><span class="term">endpoint</span></dt>
<dd><p>
An endpoint on the local machine to which the stream socket will
be bound.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload6.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload6.exceptions"></a></span><a class="link" href="overload6.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload6.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload5.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload7.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,93 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (7 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload6.html" title="basic_stream_socket::basic_stream_socket (6 of 10 overloads)">
<link rel="next" href="overload8.html" title="basic_stream_socket::basic_stream_socket (8 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload6.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload8.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload7"></a><a class="link" href="overload7.html" title="basic_stream_socket::basic_stream_socket (7 of 10 overloads)">basic_stream_socket::basic_stream_socket
(7 of 10 overloads)</a>
</h5></div></div></div>
<p>
Construct a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
on an existing native socket.
</p>
<pre class="programlisting">basic_stream_socket(
const executor_type &amp; ex,
const protocol_type &amp; protocol,
const native_handle_type &amp; native_socket);
</pre>
<p>
This constructor creates a stream socket object to hold an existing native
socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload7.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload7.parameters"></a></span><a class="link" href="overload7.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload7.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ex</span></dt>
<dd><p>
The I/O executor that the socket will use, by default, to dispatch
handlers for any asynchronous operations performed on the socket.
</p></dd>
<dt><span class="term">protocol</span></dt>
<dd><p>
An object specifying protocol parameters to be used.
</p></dd>
<dt><span class="term">native_socket</span></dt>
<dd><p>
The new underlying socket implementation.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload7.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload7.exceptions"></a></span><a class="link" href="overload7.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload7.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload6.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload8.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,97 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (8 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload7.html" title="basic_stream_socket::basic_stream_socket (7 of 10 overloads)">
<link rel="next" href="overload9.html" title="basic_stream_socket::basic_stream_socket (9 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload7.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload9.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload8"></a><a class="link" href="overload8.html" title="basic_stream_socket::basic_stream_socket (8 of 10 overloads)">basic_stream_socket::basic_stream_socket
(8 of 10 overloads)</a>
</h5></div></div></div>
<p>
Construct a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
on an existing native socket.
</p>
<pre class="programlisting">template&lt;
typename ExecutionContext&gt;
basic_stream_socket(
ExecutionContext &amp; context,
const protocol_type &amp; protocol,
const native_handle_type &amp; native_socket,
typename constraint&lt; is_convertible&lt; ExecutionContext &amp;, execution_context &amp; &gt;::value &gt;::type = 0);
</pre>
<p>
This constructor creates a stream socket object to hold an existing native
socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload8.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload8.parameters"></a></span><a class="link" href="overload8.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload8.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">context</span></dt>
<dd><p>
An execution context which provides the I/O executor that the socket
will use, by default, to dispatch handlers for any asynchronous
operations performed on the socket.
</p></dd>
<dt><span class="term">protocol</span></dt>
<dd><p>
An object specifying protocol parameters to be used.
</p></dd>
<dt><span class="term">native_socket</span></dt>
<dd><p>
The new underlying socket implementation.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload8.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload8.exceptions"></a></span><a class="link" href="overload8.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload8.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload7.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload9.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,78 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::basic_stream_socket (9 of 10 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket::basic_stream_socket">
<link rel="prev" href="overload8.html" title="basic_stream_socket::basic_stream_socket (8 of 10 overloads)">
<link rel="next" href="overload10.html" title="basic_stream_socket::basic_stream_socket (10 of 10 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload8.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload10.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload9"></a><a class="link" href="overload9.html" title="basic_stream_socket::basic_stream_socket (9 of 10 overloads)">basic_stream_socket::basic_stream_socket
(9 of 10 overloads)</a>
</h5></div></div></div>
<p>
Move-construct a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
from another.
</p>
<pre class="programlisting">basic_stream_socket(
basic_stream_socket &amp;&amp; other);
</pre>
<p>
This constructor moves a stream socket from one object to another.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload9.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload9.parameters"></a></span><a class="link" href="overload9.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload9.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">other</span></dt>
<dd><p>
The other <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
object from which the move will occur.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload9.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.basic_stream_socket.overload9.remarks"></a></span><a class="link" href="overload9.html#boost_asio.reference.basic_stream_socket.basic_stream_socket.overload9.remarks">Remarks</a>
</h6>
<p>
Following the move, the moved-from object is in the same state as if
constructed using the <code class="computeroutput">basic_stream_socket(const executor_type&amp;)</code>
constructor.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload8.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload10.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,58 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::bind</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="basic_stream_socket/overload10.html" title="basic_stream_socket::basic_stream_socket (10 of 10 overloads)">
<link rel="next" href="bind/overload1.html" title="basic_stream_socket::bind (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="basic_stream_socket/overload10.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="bind/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.bind"></a><a class="link" href="bind.html" title="basic_stream_socket::bind">basic_stream_socket::bind</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.bind"></a>
Bind
the socket to the given local endpoint.
</p>
<pre class="programlisting">void <a class="link" href="bind/overload1.html" title="basic_stream_socket::bind (1 of 2 overloads)">bind</a>(
const endpoint_type &amp; endpoint);
<span class="emphasis"><em>» <a class="link" href="bind/overload1.html" title="basic_stream_socket::bind (1 of 2 overloads)">more...</a></em></span>
void <a class="link" href="bind/overload2.html" title="basic_stream_socket::bind (2 of 2 overloads)">bind</a>(
const endpoint_type &amp; endpoint,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="bind/overload2.html" title="basic_stream_socket::bind (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="basic_stream_socket/overload10.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="bind/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,93 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::bind (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../bind.html" title="basic_stream_socket::bind">
<link rel="prev" href="../bind.html" title="basic_stream_socket::bind">
<link rel="next" href="overload2.html" title="basic_stream_socket::bind (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../bind.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../bind.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.bind.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::bind (1 of 2 overloads)">basic_stream_socket::bind
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Bind the socket to the given local endpoint.
</p>
<pre class="programlisting">void bind(
const endpoint_type &amp; endpoint);
</pre>
<p>
This function binds the socket to the specified endpoint on the local
machine.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.bind.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.bind.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.bind.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">endpoint</span></dt>
<dd><p>
An endpoint on the local machine to which the socket will be bound.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.bind.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.bind.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.bind.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.bind.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.bind.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.bind.overload1.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
socket.open(boost::asio::ip::tcp::v4());
socket.bind(boost::asio::ip::tcp::endpoint(
boost::asio::ip::tcp::v4(), 12345));
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../bind.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../bind.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,90 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::bind (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../bind.html" title="basic_stream_socket::bind">
<link rel="prev" href="overload1.html" title="basic_stream_socket::bind (1 of 2 overloads)">
<link rel="next" href="../broadcast.html" title="basic_stream_socket::broadcast">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../bind.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../broadcast.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.bind.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::bind (2 of 2 overloads)">basic_stream_socket::bind
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Bind the socket to the given local endpoint.
</p>
<pre class="programlisting">void bind(
const endpoint_type &amp; endpoint,
boost::system::error_code &amp; ec);
</pre>
<p>
This function binds the socket to the specified endpoint on the local
machine.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.bind.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.bind.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.bind.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">endpoint</span></dt>
<dd><p>
An endpoint on the local machine to which the socket will be bound.
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.bind.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.bind.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.bind.overload2.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
socket.open(boost::asio::ip::tcp::v4());
boost::system::error_code ec;
socket.bind(boost::asio::ip::tcp::endpoint(
boost::asio::ip::tcp::v4(), 12345), ec);
if (ec)
{
// An error occurred.
}
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../bind.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../broadcast.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,88 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::broadcast</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="bind/overload2.html" title="basic_stream_socket::bind (2 of 2 overloads)">
<link rel="next" href="bytes_readable.html" title="basic_stream_socket::bytes_readable">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="bind/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="bytes_readable.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.broadcast"></a><a class="link" href="broadcast.html" title="basic_stream_socket::broadcast">basic_stream_socket::broadcast</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.broadcast"></a>
Socket
option to permit sending of broadcast messages.
</p>
<pre class="programlisting">typedef implementation_defined broadcast;
</pre>
<p>
Implements the SOL_SOCKET/SO_BROADCAST socket option.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.broadcast.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.broadcast.examples"></a></span><a class="link" href="broadcast.html#boost_asio.reference.basic_stream_socket.broadcast.examples">Examples</a>
</h6>
<p>
Setting the option:
</p>
<pre class="programlisting">boost::asio::ip::udp::socket socket(my_context);
...
boost::asio::socket_base::broadcast option(true);
socket.set_option(option);
</pre>
<p>
Getting the current option value:
</p>
<pre class="programlisting">boost::asio::ip::udp::socket socket(my_context);
...
boost::asio::socket_base::broadcast option;
socket.get_option(option);
bool is_set = option.value();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.broadcast.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.broadcast.requirements"></a></span><a class="link" href="broadcast.html#boost_asio.reference.basic_stream_socket.broadcast.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="bind/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="bytes_readable.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,77 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::bytes_readable</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="broadcast.html" title="basic_stream_socket::broadcast">
<link rel="next" href="cancel.html" title="basic_stream_socket::cancel">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="broadcast.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="cancel.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.bytes_readable"></a><a class="link" href="bytes_readable.html" title="basic_stream_socket::bytes_readable">basic_stream_socket::bytes_readable</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.bytes_readable"></a>
IO
control command to get the amount of data that can be read without blocking.
</p>
<pre class="programlisting">typedef implementation_defined bytes_readable;
</pre>
<p>
Implements the FIONREAD IO control command.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.bytes_readable.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.bytes_readable.example"></a></span><a class="link" href="bytes_readable.html#boost_asio.reference.basic_stream_socket.bytes_readable.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::bytes_readable command(true);
socket.io_control(command);
std::size_t bytes_readable = command.get();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.bytes_readable.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.bytes_readable.requirements"></a></span><a class="link" href="bytes_readable.html#boost_asio.reference.basic_stream_socket.bytes_readable.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="broadcast.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="cancel.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,56 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::cancel</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="bytes_readable.html" title="basic_stream_socket::bytes_readable">
<link rel="next" href="cancel/overload1.html" title="basic_stream_socket::cancel (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="bytes_readable.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="cancel/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.cancel"></a><a class="link" href="cancel.html" title="basic_stream_socket::cancel">basic_stream_socket::cancel</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.cancel"></a>
Cancel
all asynchronous operations associated with the socket.
</p>
<pre class="programlisting">void <a class="link" href="cancel/overload1.html" title="basic_stream_socket::cancel (1 of 2 overloads)">cancel</a>();
<span class="emphasis"><em>» <a class="link" href="cancel/overload1.html" title="basic_stream_socket::cancel (1 of 2 overloads)">more...</a></em></span>
void <a class="link" href="cancel/overload2.html" title="basic_stream_socket::cancel (2 of 2 overloads)">cancel</a>(
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="cancel/overload2.html" title="basic_stream_socket::cancel (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="bytes_readable.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="cancel/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,112 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::cancel (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../cancel.html" title="basic_stream_socket::cancel">
<link rel="prev" href="../cancel.html" title="basic_stream_socket::cancel">
<link rel="next" href="overload2.html" title="basic_stream_socket::cancel (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../cancel.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../cancel.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.cancel.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::cancel (1 of 2 overloads)">basic_stream_socket::cancel
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Cancel all asynchronous operations associated with the socket.
</p>
<pre class="programlisting">void cancel();
</pre>
<p>
This function causes all outstanding asynchronous connect, send and receive
operations to finish immediately, and the handlers for cancelled operations
will be passed the <code class="computeroutput">boost::asio::error::operation_aborted</code>
error.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.cancel.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.cancel.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.cancel.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.cancel.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.cancel.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.cancel.overload1.remarks">Remarks</a>
</h6>
<p>
Calls to <code class="computeroutput">cancel()</code> will always fail with <code class="computeroutput">boost::asio::error::operation_not_supported</code>
when run on Windows XP, Windows Server 2003, and earlier versions of
Windows, unless BOOST_ASIO_ENABLE_CANCELIO is defined. However, the CancelIo
function has two issues that should be considered before enabling its
use:
</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem">
It will only cancel asynchronous operations that were initiated in
the current thread.
</li>
<li class="listitem">
It can appear to complete without error, but the request to cancel
the unfinished operations may be silently ignored by the operating
system. Whether it works or not seems to depend on the drivers that
are installed.
</li>
</ul></div>
<p>
For portable cancellation, consider using one of the following alternatives:
</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem">
Disable asio's I/O completion port backend by defining BOOST_ASIO_DISABLE_IOCP.
</li>
<li class="listitem">
Use the <code class="computeroutput">close()</code> function to simultaneously cancel the
outstanding operations and close the socket.
</li>
</ul></div>
<p>
When running on Windows Vista, Windows Server 2008, and later, the CancelIoEx
function is always used. This function does not have the problems described
above.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../cancel.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../cancel.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,113 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::cancel (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../cancel.html" title="basic_stream_socket::cancel">
<link rel="prev" href="overload1.html" title="basic_stream_socket::cancel (1 of 2 overloads)">
<link rel="next" href="../close.html" title="basic_stream_socket::close">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../cancel.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../close.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.cancel.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::cancel (2 of 2 overloads)">basic_stream_socket::cancel
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Cancel all asynchronous operations associated with the socket.
</p>
<pre class="programlisting">void cancel(
boost::system::error_code &amp; ec);
</pre>
<p>
This function causes all outstanding asynchronous connect, send and receive
operations to finish immediately, and the handlers for cancelled operations
will be passed the <code class="computeroutput">boost::asio::error::operation_aborted</code>
error.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.cancel.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.cancel.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.cancel.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.cancel.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.cancel.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.cancel.overload2.remarks">Remarks</a>
</h6>
<p>
Calls to <code class="computeroutput">cancel()</code> will always fail with <code class="computeroutput">boost::asio::error::operation_not_supported</code>
when run on Windows XP, Windows Server 2003, and earlier versions of
Windows, unless BOOST_ASIO_ENABLE_CANCELIO is defined. However, the CancelIo
function has two issues that should be considered before enabling its
use:
</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem">
It will only cancel asynchronous operations that were initiated in
the current thread.
</li>
<li class="listitem">
It can appear to complete without error, but the request to cancel
the unfinished operations may be silently ignored by the operating
system. Whether it works or not seems to depend on the drivers that
are installed.
</li>
</ul></div>
<p>
For portable cancellation, consider using one of the following alternatives:
</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem">
Disable asio's I/O completion port backend by defining BOOST_ASIO_DISABLE_IOCP.
</li>
<li class="listitem">
Use the <code class="computeroutput">close()</code> function to simultaneously cancel the
outstanding operations and close the socket.
</li>
</ul></div>
<p>
When running on Windows Vista, Windows Server 2008, and later, the CancelIoEx
function is always used. This function does not have the problems described
above.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../cancel.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../close.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,56 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::close</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="cancel/overload2.html" title="basic_stream_socket::cancel (2 of 2 overloads)">
<link rel="next" href="close/overload1.html" title="basic_stream_socket::close (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="cancel/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="close/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.close"></a><a class="link" href="close.html" title="basic_stream_socket::close">basic_stream_socket::close</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.close"></a>
Close
the socket.
</p>
<pre class="programlisting">void <a class="link" href="close/overload1.html" title="basic_stream_socket::close (1 of 2 overloads)">close</a>();
<span class="emphasis"><em>» <a class="link" href="close/overload1.html" title="basic_stream_socket::close (1 of 2 overloads)">more...</a></em></span>
void <a class="link" href="close/overload2.html" title="basic_stream_socket::close (2 of 2 overloads)">close</a>(
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="close/overload2.html" title="basic_stream_socket::close (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="cancel/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="close/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,80 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::close (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../close.html" title="basic_stream_socket::close">
<link rel="prev" href="../close.html" title="basic_stream_socket::close">
<link rel="next" href="overload2.html" title="basic_stream_socket::close (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../close.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../close.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.close.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::close (1 of 2 overloads)">basic_stream_socket::close
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Close the socket.
</p>
<pre class="programlisting">void close();
</pre>
<p>
This function is used to close the socket. Any asynchronous send, receive
or connect operations will be cancelled immediately, and will complete
with the <code class="computeroutput">boost::asio::error::operation_aborted</code> error.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.close.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.close.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.close.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure. Note that, even if the function indicates an
error, the underlying descriptor is closed.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.close.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.close.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.close.overload1.remarks">Remarks</a>
</h6>
<p>
For portable behaviour with respect to graceful closure of a connected
socket, call <code class="computeroutput">shutdown()</code> before closing the socket.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../close.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../close.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,94 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::close (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../close.html" title="basic_stream_socket::close">
<link rel="prev" href="overload1.html" title="basic_stream_socket::close (1 of 2 overloads)">
<link rel="next" href="../connect.html" title="basic_stream_socket::connect">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../close.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../connect.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.close.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::close (2 of 2 overloads)">basic_stream_socket::close
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Close the socket.
</p>
<pre class="programlisting">void close(
boost::system::error_code &amp; ec);
</pre>
<p>
This function is used to close the socket. Any asynchronous send, receive
or connect operations will be cancelled immediately, and will complete
with the <code class="computeroutput">boost::asio::error::operation_aborted</code> error.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.close.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.close.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.close.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any. Note that, even if
the function indicates an error, the underlying descriptor is closed.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.close.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.close.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.close.overload2.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::system::error_code ec;
socket.close(ec);
if (ec)
{
// An error occurred.
}
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.close.overload2.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.close.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.close.overload2.remarks">Remarks</a>
</h6>
<p>
For portable behaviour with respect to graceful closure of a connected
socket, call <code class="computeroutput">shutdown()</code> before closing the socket.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../close.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../connect.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,58 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::connect</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="close/overload2.html" title="basic_stream_socket::close (2 of 2 overloads)">
<link rel="next" href="connect/overload1.html" title="basic_stream_socket::connect (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="close/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="connect/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.connect"></a><a class="link" href="connect.html" title="basic_stream_socket::connect">basic_stream_socket::connect</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.connect"></a>
Connect
the socket to the specified endpoint.
</p>
<pre class="programlisting">void <a class="link" href="connect/overload1.html" title="basic_stream_socket::connect (1 of 2 overloads)">connect</a>(
const endpoint_type &amp; peer_endpoint);
<span class="emphasis"><em>» <a class="link" href="connect/overload1.html" title="basic_stream_socket::connect (1 of 2 overloads)">more...</a></em></span>
void <a class="link" href="connect/overload2.html" title="basic_stream_socket::connect (2 of 2 overloads)">connect</a>(
const endpoint_type &amp; peer_endpoint,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="connect/overload2.html" title="basic_stream_socket::connect (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="close/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="connect/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,99 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::connect (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../connect.html" title="basic_stream_socket::connect">
<link rel="prev" href="../connect.html" title="basic_stream_socket::connect">
<link rel="next" href="overload2.html" title="basic_stream_socket::connect (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../connect.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../connect.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.connect.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::connect (1 of 2 overloads)">basic_stream_socket::connect
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Connect the socket to the specified endpoint.
</p>
<pre class="programlisting">void connect(
const endpoint_type &amp; peer_endpoint);
</pre>
<p>
This function is used to connect a socket to the specified remote endpoint.
The function call will block until the connection is successfully made
or an error occurs.
</p>
<p>
The socket is automatically opened if it is not already open. If the
connect fails, and the socket was automatically opened, the socket is
not returned to the closed state.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.connect.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.connect.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.connect.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">peer_endpoint</span></dt>
<dd><p>
The remote endpoint to which the socket will be connected.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.connect.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.connect.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.connect.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.connect.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.connect.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.connect.overload1.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
boost::asio::ip::tcp::endpoint endpoint(
boost::asio::ip::address::from_string("1.2.3.4"), 12345);
socket.connect(endpoint);
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../connect.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../connect.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,96 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::connect (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../connect.html" title="basic_stream_socket::connect">
<link rel="prev" href="overload1.html" title="basic_stream_socket::connect (1 of 2 overloads)">
<link rel="next" href="../debug.html" title="basic_stream_socket::debug">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../connect.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../debug.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.connect.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::connect (2 of 2 overloads)">basic_stream_socket::connect
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Connect the socket to the specified endpoint.
</p>
<pre class="programlisting">void connect(
const endpoint_type &amp; peer_endpoint,
boost::system::error_code &amp; ec);
</pre>
<p>
This function is used to connect a socket to the specified remote endpoint.
The function call will block until the connection is successfully made
or an error occurs.
</p>
<p>
The socket is automatically opened if it is not already open. If the
connect fails, and the socket was automatically opened, the socket is
not returned to the closed state.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.connect.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.connect.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.connect.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">peer_endpoint</span></dt>
<dd><p>
The remote endpoint to which the socket will be connected.
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.connect.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.connect.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.connect.overload2.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
boost::asio::ip::tcp::endpoint endpoint(
boost::asio::ip::address::from_string("1.2.3.4"), 12345);
boost::system::error_code ec;
socket.connect(endpoint, ec);
if (ec)
{
// An error occurred.
}
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../connect.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../debug.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,88 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::debug</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="connect/overload2.html" title="basic_stream_socket::connect (2 of 2 overloads)">
<link rel="next" href="do_not_route.html" title="basic_stream_socket::do_not_route">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="connect/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="do_not_route.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.debug"></a><a class="link" href="debug.html" title="basic_stream_socket::debug">basic_stream_socket::debug</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.debug"></a>
Socket
option to enable socket-level debugging.
</p>
<pre class="programlisting">typedef implementation_defined debug;
</pre>
<p>
Implements the SOL_SOCKET/SO_DEBUG socket option.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.debug.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.debug.examples"></a></span><a class="link" href="debug.html#boost_asio.reference.basic_stream_socket.debug.examples">Examples</a>
</h6>
<p>
Setting the option:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::debug option(true);
socket.set_option(option);
</pre>
<p>
Getting the current option value:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::debug option;
socket.get_option(option);
bool is_set = option.value();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.debug.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.debug.requirements"></a></span><a class="link" href="debug.html#boost_asio.reference.basic_stream_socket.debug.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="connect/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="do_not_route.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,88 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::do_not_route</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="debug.html" title="basic_stream_socket::debug">
<link rel="next" href="enable_connection_aborted.html" title="basic_stream_socket::enable_connection_aborted">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="debug.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="enable_connection_aborted.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.do_not_route"></a><a class="link" href="do_not_route.html" title="basic_stream_socket::do_not_route">basic_stream_socket::do_not_route</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.do_not_route"></a>
Socket
option to prevent routing, use local interfaces only.
</p>
<pre class="programlisting">typedef implementation_defined do_not_route;
</pre>
<p>
Implements the SOL_SOCKET/SO_DONTROUTE socket option.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.do_not_route.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.do_not_route.examples"></a></span><a class="link" href="do_not_route.html#boost_asio.reference.basic_stream_socket.do_not_route.examples">Examples</a>
</h6>
<p>
Setting the option:
</p>
<pre class="programlisting">boost::asio::ip::udp::socket socket(my_context);
...
boost::asio::socket_base::do_not_route option(true);
socket.set_option(option);
</pre>
<p>
Getting the current option value:
</p>
<pre class="programlisting">boost::asio::ip::udp::socket socket(my_context);
...
boost::asio::socket_base::do_not_route option;
socket.get_option(option);
bool is_set = option.value();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.do_not_route.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.do_not_route.requirements"></a></span><a class="link" href="do_not_route.html#boost_asio.reference.basic_stream_socket.do_not_route.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="debug.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="enable_connection_aborted.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,90 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::enable_connection_aborted</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="do_not_route.html" title="basic_stream_socket::do_not_route">
<link rel="next" href="endpoint_type.html" title="basic_stream_socket::endpoint_type">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="do_not_route.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="endpoint_type.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.enable_connection_aborted"></a><a class="link" href="enable_connection_aborted.html" title="basic_stream_socket::enable_connection_aborted">basic_stream_socket::enable_connection_aborted</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.enable_connection_aborted"></a>
Socket
option to report aborted connections on accept.
</p>
<pre class="programlisting">typedef implementation_defined enable_connection_aborted;
</pre>
<p>
Implements a custom socket option that determines whether or not an accept
operation is permitted to fail with <code class="computeroutput">boost::asio::error::connection_aborted</code>.
By default the option is false.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.enable_connection_aborted.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.enable_connection_aborted.examples"></a></span><a class="link" href="enable_connection_aborted.html#boost_asio.reference.basic_stream_socket.enable_connection_aborted.examples">Examples</a>
</h6>
<p>
Setting the option:
</p>
<pre class="programlisting">boost::asio::ip::tcp::acceptor acceptor(my_context);
...
boost::asio::socket_base::enable_connection_aborted option(true);
acceptor.set_option(option);
</pre>
<p>
Getting the current option value:
</p>
<pre class="programlisting">boost::asio::ip::tcp::acceptor acceptor(my_context);
...
boost::asio::socket_base::enable_connection_aborted option;
acceptor.get_option(option);
bool is_set = option.value();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.enable_connection_aborted.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.enable_connection_aborted.requirements"></a></span><a class="link" href="enable_connection_aborted.html#boost_asio.reference.basic_stream_socket.enable_connection_aborted.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="do_not_route.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="endpoint_type.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,61 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::endpoint_type</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="enable_connection_aborted.html" title="basic_stream_socket::enable_connection_aborted">
<link rel="next" href="executor_type.html" title="basic_stream_socket::executor_type">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="enable_connection_aborted.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="executor_type.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.endpoint_type"></a><a class="link" href="endpoint_type.html" title="basic_stream_socket::endpoint_type">basic_stream_socket::endpoint_type</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.endpoint_type"></a>
The
endpoint type.
</p>
<pre class="programlisting">typedef Protocol::endpoint endpoint_type;
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.endpoint_type.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.endpoint_type.requirements"></a></span><a class="link" href="endpoint_type.html#boost_asio.reference.basic_stream_socket.endpoint_type.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="enable_connection_aborted.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="executor_type.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,61 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::executor_type</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="endpoint_type.html" title="basic_stream_socket::endpoint_type">
<link rel="next" href="get_executor.html" title="basic_stream_socket::get_executor">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="endpoint_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="get_executor.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.executor_type"></a><a class="link" href="executor_type.html" title="basic_stream_socket::executor_type">basic_stream_socket::executor_type</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.executor_type"></a>
The
type of the executor associated with the object.
</p>
<pre class="programlisting">typedef Executor executor_type;
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.executor_type.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.executor_type.requirements"></a></span><a class="link" href="executor_type.html#boost_asio.reference.basic_stream_socket.executor_type.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="endpoint_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="get_executor.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,54 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::get_executor</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="executor_type.html" title="basic_stream_socket::executor_type">
<link rel="next" href="get_option.html" title="basic_stream_socket::get_option">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="executor_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="get_option.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.get_executor"></a><a class="link" href="get_executor.html" title="basic_stream_socket::get_executor">basic_stream_socket::get_executor</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.get_executor"></a>
Get
the executor associated with the object.
</p>
<pre class="programlisting">executor_type get_executor();
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="executor_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="get_option.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,62 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::get_option</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="get_executor.html" title="basic_stream_socket::get_executor">
<link rel="next" href="get_option/overload1.html" title="basic_stream_socket::get_option (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="get_executor.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="get_option/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.get_option"></a><a class="link" href="get_option.html" title="basic_stream_socket::get_option">basic_stream_socket::get_option</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.get_option"></a>
Get
an option from the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../GettableSocketOption.html" title="Gettable socket option requirements">GettableSocketOption</a>&gt;
void <a class="link" href="get_option/overload1.html" title="basic_stream_socket::get_option (1 of 2 overloads)">get_option</a>(
GettableSocketOption &amp; option) const;
<span class="emphasis"><em>» <a class="link" href="get_option/overload1.html" title="basic_stream_socket::get_option (1 of 2 overloads)">more...</a></em></span>
template&lt;
typename <a class="link" href="../GettableSocketOption.html" title="Gettable socket option requirements">GettableSocketOption</a>&gt;
void <a class="link" href="get_option/overload2.html" title="basic_stream_socket::get_option (2 of 2 overloads)">get_option</a>(
GettableSocketOption &amp; option,
boost::system::error_code &amp; ec) const;
<span class="emphasis"><em>» <a class="link" href="get_option/overload2.html" title="basic_stream_socket::get_option (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="get_executor.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="get_option/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,98 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::get_option (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../get_option.html" title="basic_stream_socket::get_option">
<link rel="prev" href="../get_option.html" title="basic_stream_socket::get_option">
<link rel="next" href="overload2.html" title="basic_stream_socket::get_option (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../get_option.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../get_option.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.get_option.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::get_option (1 of 2 overloads)">basic_stream_socket::get_option
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Get an option from the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../GettableSocketOption.html" title="Gettable socket option requirements">GettableSocketOption</a>&gt;
void get_option(
GettableSocketOption &amp; option) const;
</pre>
<p>
This function is used to get the current value of an option on the socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.get_option.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.get_option.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.get_option.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">option</span></dt>
<dd><p>
The option value to be obtained from the socket.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.get_option.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.get_option.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.get_option.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.get_option.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.get_option.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.get_option.overload1.example">Example</a>
</h6>
<p>
Getting the value of the SOL_SOCKET/SO_KEEPALIVE option:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::ip::tcp::socket::keep_alive option;
socket.get_option(option);
bool is_set = option.value();
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../get_option.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../get_option.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,95 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::get_option (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../get_option.html" title="basic_stream_socket::get_option">
<link rel="prev" href="overload1.html" title="basic_stream_socket::get_option (1 of 2 overloads)">
<link rel="next" href="../io_control.html" title="basic_stream_socket::io_control">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../get_option.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../io_control.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.get_option.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::get_option (2 of 2 overloads)">basic_stream_socket::get_option
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Get an option from the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../GettableSocketOption.html" title="Gettable socket option requirements">GettableSocketOption</a>&gt;
void get_option(
GettableSocketOption &amp; option,
boost::system::error_code &amp; ec) const;
</pre>
<p>
This function is used to get the current value of an option on the socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.get_option.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.get_option.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.get_option.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">option</span></dt>
<dd><p>
The option value to be obtained from the socket.
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.get_option.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.get_option.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.get_option.overload2.example">Example</a>
</h6>
<p>
Getting the value of the SOL_SOCKET/SO_KEEPALIVE option:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::ip::tcp::socket::keep_alive option;
boost::system::error_code ec;
socket.get_option(option, ec);
if (ec)
{
// An error occurred.
}
bool is_set = option.value();
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../get_option.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../io_control.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,62 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::io_control</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="get_option/overload2.html" title="basic_stream_socket::get_option (2 of 2 overloads)">
<link rel="next" href="io_control/overload1.html" title="basic_stream_socket::io_control (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="get_option/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="io_control/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.io_control"></a><a class="link" href="io_control.html" title="basic_stream_socket::io_control">basic_stream_socket::io_control</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.io_control"></a>
Perform
an IO control command on the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../IoControlCommand.html" title="I/O control command requirements">IoControlCommand</a>&gt;
void <a class="link" href="io_control/overload1.html" title="basic_stream_socket::io_control (1 of 2 overloads)">io_control</a>(
IoControlCommand &amp; command);
<span class="emphasis"><em>» <a class="link" href="io_control/overload1.html" title="basic_stream_socket::io_control (1 of 2 overloads)">more...</a></em></span>
template&lt;
typename <a class="link" href="../IoControlCommand.html" title="I/O control command requirements">IoControlCommand</a>&gt;
void <a class="link" href="io_control/overload2.html" title="basic_stream_socket::io_control (2 of 2 overloads)">io_control</a>(
IoControlCommand &amp; command,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="io_control/overload2.html" title="basic_stream_socket::io_control (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="get_option/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="io_control/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,98 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::io_control (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../io_control.html" title="basic_stream_socket::io_control">
<link rel="prev" href="../io_control.html" title="basic_stream_socket::io_control">
<link rel="next" href="overload2.html" title="basic_stream_socket::io_control (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../io_control.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../io_control.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.io_control.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::io_control (1 of 2 overloads)">basic_stream_socket::io_control
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Perform an IO control command on the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../IoControlCommand.html" title="I/O control command requirements">IoControlCommand</a>&gt;
void io_control(
IoControlCommand &amp; command);
</pre>
<p>
This function is used to execute an IO control command on the socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.io_control.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.io_control.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.io_control.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">command</span></dt>
<dd><p>
The IO control command to be performed on the socket.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.io_control.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.io_control.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.io_control.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.io_control.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.io_control.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.io_control.overload1.example">Example</a>
</h6>
<p>
Getting the number of bytes ready to read:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::ip::tcp::socket::bytes_readable command;
socket.io_control(command);
std::size_t bytes_readable = command.get();
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../io_control.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../io_control.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,95 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::io_control (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../io_control.html" title="basic_stream_socket::io_control">
<link rel="prev" href="overload1.html" title="basic_stream_socket::io_control (1 of 2 overloads)">
<link rel="next" href="../is_open.html" title="basic_stream_socket::is_open">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../io_control.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../is_open.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.io_control.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::io_control (2 of 2 overloads)">basic_stream_socket::io_control
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Perform an IO control command on the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../IoControlCommand.html" title="I/O control command requirements">IoControlCommand</a>&gt;
void io_control(
IoControlCommand &amp; command,
boost::system::error_code &amp; ec);
</pre>
<p>
This function is used to execute an IO control command on the socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.io_control.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.io_control.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.io_control.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">command</span></dt>
<dd><p>
The IO control command to be performed on the socket.
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.io_control.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.io_control.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.io_control.overload2.example">Example</a>
</h6>
<p>
Getting the number of bytes ready to read:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::ip::tcp::socket::bytes_readable command;
boost::system::error_code ec;
socket.io_control(command, ec);
if (ec)
{
// An error occurred.
}
std::size_t bytes_readable = command.get();
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../io_control.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../is_open.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,54 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::is_open</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="io_control/overload2.html" title="basic_stream_socket::io_control (2 of 2 overloads)">
<link rel="next" href="keep_alive.html" title="basic_stream_socket::keep_alive">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="io_control/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="keep_alive.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.is_open"></a><a class="link" href="is_open.html" title="basic_stream_socket::is_open">basic_stream_socket::is_open</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.is_open"></a>
Determine
whether the socket is open.
</p>
<pre class="programlisting">bool is_open() const;
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="io_control/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="keep_alive.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,88 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::keep_alive</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="is_open.html" title="basic_stream_socket::is_open">
<link rel="next" href="linger.html" title="basic_stream_socket::linger">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="is_open.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="linger.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.keep_alive"></a><a class="link" href="keep_alive.html" title="basic_stream_socket::keep_alive">basic_stream_socket::keep_alive</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.keep_alive"></a>
Socket
option to send keep-alives.
</p>
<pre class="programlisting">typedef implementation_defined keep_alive;
</pre>
<p>
Implements the SOL_SOCKET/SO_KEEPALIVE socket option.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.keep_alive.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.keep_alive.examples"></a></span><a class="link" href="keep_alive.html#boost_asio.reference.basic_stream_socket.keep_alive.examples">Examples</a>
</h6>
<p>
Setting the option:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::keep_alive option(true);
socket.set_option(option);
</pre>
<p>
Getting the current option value:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::keep_alive option;
socket.get_option(option);
bool is_set = option.value();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.keep_alive.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.keep_alive.requirements"></a></span><a class="link" href="keep_alive.html#boost_asio.reference.basic_stream_socket.keep_alive.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="is_open.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="linger.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,90 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::linger</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="keep_alive.html" title="basic_stream_socket::keep_alive">
<link rel="next" href="local_endpoint.html" title="basic_stream_socket::local_endpoint">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="keep_alive.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="local_endpoint.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.linger"></a><a class="link" href="linger.html" title="basic_stream_socket::linger">basic_stream_socket::linger</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.linger"></a>
Socket
option to specify whether the socket lingers on close if unsent data is
present.
</p>
<pre class="programlisting">typedef implementation_defined linger;
</pre>
<p>
Implements the SOL_SOCKET/SO_LINGER socket option.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.linger.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.linger.examples"></a></span><a class="link" href="linger.html#boost_asio.reference.basic_stream_socket.linger.examples">Examples</a>
</h6>
<p>
Setting the option:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::linger option(true, 30);
socket.set_option(option);
</pre>
<p>
Getting the current option value:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::linger option;
socket.get_option(option);
bool is_set = option.enabled();
unsigned short timeout = option.timeout();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.linger.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.linger.requirements"></a></span><a class="link" href="linger.html#boost_asio.reference.basic_stream_socket.linger.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="keep_alive.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="local_endpoint.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,56 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::local_endpoint</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="linger.html" title="basic_stream_socket::linger">
<link rel="next" href="local_endpoint/overload1.html" title="basic_stream_socket::local_endpoint (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="linger.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="local_endpoint/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.local_endpoint"></a><a class="link" href="local_endpoint.html" title="basic_stream_socket::local_endpoint">basic_stream_socket::local_endpoint</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.local_endpoint"></a>
Get
the local endpoint of the socket.
</p>
<pre class="programlisting">endpoint_type <a class="link" href="local_endpoint/overload1.html" title="basic_stream_socket::local_endpoint (1 of 2 overloads)">local_endpoint</a>() const;
<span class="emphasis"><em>» <a class="link" href="local_endpoint/overload1.html" title="basic_stream_socket::local_endpoint (1 of 2 overloads)">more...</a></em></span>
endpoint_type <a class="link" href="local_endpoint/overload2.html" title="basic_stream_socket::local_endpoint (2 of 2 overloads)">local_endpoint</a>(
boost::system::error_code &amp; ec) const;
<span class="emphasis"><em>» <a class="link" href="local_endpoint/overload2.html" title="basic_stream_socket::local_endpoint (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="linger.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="local_endpoint/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,85 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::local_endpoint (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../local_endpoint.html" title="basic_stream_socket::local_endpoint">
<link rel="prev" href="../local_endpoint.html" title="basic_stream_socket::local_endpoint">
<link rel="next" href="overload2.html" title="basic_stream_socket::local_endpoint (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../local_endpoint.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../local_endpoint.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::local_endpoint (1 of 2 overloads)">basic_stream_socket::local_endpoint
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Get the local endpoint of the socket.
</p>
<pre class="programlisting">endpoint_type local_endpoint() const;
</pre>
<p>
This function is used to obtain the locally bound endpoint of the socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload1.return_value"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.local_endpoint.overload1.return_value">Return
Value</a>
</h6>
<p>
An object that represents the local endpoint of the socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.local_endpoint.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.local_endpoint.overload1.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::ip::tcp::endpoint endpoint = socket.local_endpoint();
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../local_endpoint.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../local_endpoint.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,92 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::local_endpoint (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../local_endpoint.html" title="basic_stream_socket::local_endpoint">
<link rel="prev" href="overload1.html" title="basic_stream_socket::local_endpoint (1 of 2 overloads)">
<link rel="next" href="../lowest_layer.html" title="basic_stream_socket::lowest_layer">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../local_endpoint.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../lowest_layer.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::local_endpoint (2 of 2 overloads)">basic_stream_socket::local_endpoint
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Get the local endpoint of the socket.
</p>
<pre class="programlisting">endpoint_type local_endpoint(
boost::system::error_code &amp; ec) const;
</pre>
<p>
This function is used to obtain the locally bound endpoint of the socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.local_endpoint.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload2.return_value"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.local_endpoint.overload2.return_value">Return
Value</a>
</h6>
<p>
An object that represents the local endpoint of the socket. Returns a
default-constructed endpoint object if an error occurred.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload2.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.local_endpoint.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.local_endpoint.overload2.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::system::error_code ec;
boost::asio::ip::tcp::endpoint endpoint = socket.local_endpoint(ec);
if (ec)
{
// An error occurred.
}
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../local_endpoint.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../lowest_layer.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,58 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::lowest_layer</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="local_endpoint/overload2.html" title="basic_stream_socket::local_endpoint (2 of 2 overloads)">
<link rel="next" href="lowest_layer/overload1.html" title="basic_stream_socket::lowest_layer (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="local_endpoint/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="lowest_layer/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.lowest_layer"></a><a class="link" href="lowest_layer.html" title="basic_stream_socket::lowest_layer">basic_stream_socket::lowest_layer</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.lowest_layer"></a>
Get
a reference to the lowest layer.
</p>
<pre class="programlisting">lowest_layer_type &amp; <a class="link" href="lowest_layer/overload1.html" title="basic_stream_socket::lowest_layer (1 of 2 overloads)">lowest_layer</a>();
<span class="emphasis"><em>» <a class="link" href="lowest_layer/overload1.html" title="basic_stream_socket::lowest_layer (1 of 2 overloads)">more...</a></em></span>
</pre>
<p>
Get a const reference to the lowest layer.
</p>
<pre class="programlisting">const lowest_layer_type &amp; <a class="link" href="lowest_layer/overload2.html" title="basic_stream_socket::lowest_layer (2 of 2 overloads)">lowest_layer</a>() const;
<span class="emphasis"><em>» <a class="link" href="lowest_layer/overload2.html" title="basic_stream_socket::lowest_layer (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="local_endpoint/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="lowest_layer/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,67 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::lowest_layer (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../lowest_layer.html" title="basic_stream_socket::lowest_layer">
<link rel="prev" href="../lowest_layer.html" title="basic_stream_socket::lowest_layer">
<link rel="next" href="overload2.html" title="basic_stream_socket::lowest_layer (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../lowest_layer.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lowest_layer.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.lowest_layer.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::lowest_layer (1 of 2 overloads)">basic_stream_socket::lowest_layer
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Get a reference to the lowest layer.
</p>
<pre class="programlisting">lowest_layer_type &amp; lowest_layer();
</pre>
<p>
This function returns a reference to the lowest layer in a stack of layers.
Since a <a class="link" href="../../basic_socket.html" title="basic_socket"><code class="computeroutput">basic_socket</code></a>
cannot contain any further layers, it simply returns a reference to itself.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.lowest_layer.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.lowest_layer.overload1.return_value"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.lowest_layer.overload1.return_value">Return
Value</a>
</h6>
<p>
A reference to the lowest layer in the stack of layers. Ownership is
not transferred to the caller.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../lowest_layer.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lowest_layer.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,67 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::lowest_layer (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../lowest_layer.html" title="basic_stream_socket::lowest_layer">
<link rel="prev" href="overload1.html" title="basic_stream_socket::lowest_layer (1 of 2 overloads)">
<link rel="next" href="../lowest_layer_type.html" title="basic_stream_socket::lowest_layer_type">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lowest_layer.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../lowest_layer_type.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.lowest_layer.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::lowest_layer (2 of 2 overloads)">basic_stream_socket::lowest_layer
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Get a const reference to the lowest layer.
</p>
<pre class="programlisting">const lowest_layer_type &amp; lowest_layer() const;
</pre>
<p>
This function returns a const reference to the lowest layer in a stack
of layers. Since a <a class="link" href="../../basic_socket.html" title="basic_socket"><code class="computeroutput">basic_socket</code></a>
cannot contain any further layers, it simply returns a reference to itself.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.lowest_layer.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.lowest_layer.overload2.return_value"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.lowest_layer.overload2.return_value">Return
Value</a>
</h6>
<p>
A const reference to the lowest layer in the stack of layers. Ownership
is not transferred to the caller.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../lowest_layer.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../lowest_layer_type.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,856 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::lowest_layer_type</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="lowest_layer/overload2.html" title="basic_stream_socket::lowest_layer (2 of 2 overloads)">
<link rel="next" href="max_connections.html" title="basic_stream_socket::max_connections">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="lowest_layer/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="max_connections.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.lowest_layer_type"></a><a class="link" href="lowest_layer_type.html" title="basic_stream_socket::lowest_layer_type">basic_stream_socket::lowest_layer_type</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.lowest_layer_type"></a>
A
<a class="link" href="../basic_socket.html" title="basic_socket"><code class="computeroutput">basic_socket</code></a>
is always the lowest layer.
</p>
<pre class="programlisting">typedef basic_socket&lt; Protocol, Executor &gt; lowest_layer_type;
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.types"></a></span><a class="link" href="lowest_layer_type.html#boost_asio.reference.basic_stream_socket.lowest_layer_type.types">Types</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
<th>
<p>
Name
</p>
</th>
<th>
<p>
Description
</p>
</th>
</tr></thead>
<tbody>
<tr>
<td>
<p>
<a class="link" href="../basic_socket__rebind_executor.html" title="basic_socket::rebind_executor"><span class="bold"><strong>rebind_executor</strong></span></a>
</p>
</td>
<td>
<p>
Rebinds the socket type to another executor.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/broadcast.html" title="basic_socket::broadcast"><span class="bold"><strong>broadcast</strong></span></a>
</p>
</td>
<td>
<p>
Socket option to permit sending of broadcast messages.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/bytes_readable.html" title="basic_socket::bytes_readable"><span class="bold"><strong>bytes_readable</strong></span></a>
</p>
</td>
<td>
<p>
IO control command to get the amount of data that can be read
without blocking.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/debug.html" title="basic_socket::debug"><span class="bold"><strong>debug</strong></span></a>
</p>
</td>
<td>
<p>
Socket option to enable socket-level debugging.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/do_not_route.html" title="basic_socket::do_not_route"><span class="bold"><strong>do_not_route</strong></span></a>
</p>
</td>
<td>
<p>
Socket option to prevent routing, use local interfaces only.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/enable_connection_aborted.html" title="basic_socket::enable_connection_aborted"><span class="bold"><strong>enable_connection_aborted</strong></span></a>
</p>
</td>
<td>
<p>
Socket option to report aborted connections on accept.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/endpoint_type.html" title="basic_socket::endpoint_type"><span class="bold"><strong>endpoint_type</strong></span></a>
</p>
</td>
<td>
<p>
The endpoint type.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/executor_type.html" title="basic_socket::executor_type"><span class="bold"><strong>executor_type</strong></span></a>
</p>
</td>
<td>
<p>
The type of the executor associated with the object.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/keep_alive.html" title="basic_socket::keep_alive"><span class="bold"><strong>keep_alive</strong></span></a>
</p>
</td>
<td>
<p>
Socket option to send keep-alives.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/linger.html" title="basic_socket::linger"><span class="bold"><strong>linger</strong></span></a>
</p>
</td>
<td>
<p>
Socket option to specify whether the socket lingers on close
if unsent data is present.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/lowest_layer_type.html" title="basic_socket::lowest_layer_type"><span class="bold"><strong>lowest_layer_type</strong></span></a>
</p>
</td>
<td>
<p>
A basic_socket is always the lowest layer.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/message_flags.html" title="basic_socket::message_flags"><span class="bold"><strong>message_flags</strong></span></a>
</p>
</td>
<td>
<p>
Bitmask type for flags that can be passed to send and receive
operations.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/native_handle_type.html" title="basic_socket::native_handle_type"><span class="bold"><strong>native_handle_type</strong></span></a>
</p>
</td>
<td>
<p>
The native representation of a socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/out_of_band_inline.html" title="basic_socket::out_of_band_inline"><span class="bold"><strong>out_of_band_inline</strong></span></a>
</p>
</td>
<td>
<p>
Socket option for putting received out-of-band data inline.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/protocol_type.html" title="basic_socket::protocol_type"><span class="bold"><strong>protocol_type</strong></span></a>
</p>
</td>
<td>
<p>
The protocol type.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/receive_buffer_size.html" title="basic_socket::receive_buffer_size"><span class="bold"><strong>receive_buffer_size</strong></span></a>
</p>
</td>
<td>
<p>
Socket option for the receive buffer size of a socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/receive_low_watermark.html" title="basic_socket::receive_low_watermark"><span class="bold"><strong>receive_low_watermark</strong></span></a>
</p>
</td>
<td>
<p>
Socket option for the receive low watermark.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/reuse_address.html" title="basic_socket::reuse_address"><span class="bold"><strong>reuse_address</strong></span></a>
</p>
</td>
<td>
<p>
Socket option to allow the socket to be bound to an address that
is already in use.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/send_buffer_size.html" title="basic_socket::send_buffer_size"><span class="bold"><strong>send_buffer_size</strong></span></a>
</p>
</td>
<td>
<p>
Socket option for the send buffer size of a socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/send_low_watermark.html" title="basic_socket::send_low_watermark"><span class="bold"><strong>send_low_watermark</strong></span></a>
</p>
</td>
<td>
<p>
Socket option for the send low watermark.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/shutdown_type.html" title="basic_socket::shutdown_type"><span class="bold"><strong>shutdown_type</strong></span></a>
</p>
</td>
<td>
<p>
Different ways a socket may be shutdown.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/wait_type.html" title="basic_socket::wait_type"><span class="bold"><strong>wait_type</strong></span></a>
</p>
</td>
<td>
<p>
Wait types.
</p>
</td>
</tr>
</tbody>
</table></div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.member_functions"></a></span><a class="link" href="lowest_layer_type.html#boost_asio.reference.basic_stream_socket.lowest_layer_type.member_functions">Member
Functions</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
<th>
<p>
Name
</p>
</th>
<th>
<p>
Description
</p>
</th>
</tr></thead>
<tbody>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/assign.html" title="basic_socket::assign"><span class="bold"><strong>assign</strong></span></a>
</p>
</td>
<td>
<p>
Assign an existing native socket to the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/async_connect.html" title="basic_socket::async_connect"><span class="bold"><strong>async_connect</strong></span></a>
</p>
</td>
<td>
<p>
Start an asynchronous connect.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/async_wait.html" title="basic_socket::async_wait"><span class="bold"><strong>async_wait</strong></span></a>
</p>
</td>
<td>
<p>
Asynchronously wait for the socket to become ready to read, ready
to write, or to have pending error conditions.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/at_mark.html" title="basic_socket::at_mark"><span class="bold"><strong>at_mark</strong></span></a>
</p>
</td>
<td>
<p>
Determine whether the socket is at the out-of-band data mark.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/available.html" title="basic_socket::available"><span class="bold"><strong>available</strong></span></a>
</p>
</td>
<td>
<p>
Determine the number of bytes available for reading.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/basic_socket.html" title="basic_socket::basic_socket"><span class="bold"><strong>basic_socket</strong></span></a> <span class="silver">[constructor]</span>
</p>
</td>
<td>
<p>
Construct a basic_socket without opening it. <br> <span class="silver"></span><br> Construct
and open a basic_socket. <br> <span class="silver"></span><br> Construct a basic_socket,
opening it and binding it to the given local endpoint. <br>
<span class="silver"></span><br> Construct a basic_socket on an existing native socket.
<br> <span class="silver"></span><br> Move-construct a basic_socket from another. <br>
<span class="silver"></span><br> Move-construct a basic_socket from a socket of another
protocol type.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/bind.html" title="basic_socket::bind"><span class="bold"><strong>bind</strong></span></a>
</p>
</td>
<td>
<p>
Bind the socket to the given local endpoint.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/cancel.html" title="basic_socket::cancel"><span class="bold"><strong>cancel</strong></span></a>
</p>
</td>
<td>
<p>
Cancel all asynchronous operations associated with the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/close.html" title="basic_socket::close"><span class="bold"><strong>close</strong></span></a>
</p>
</td>
<td>
<p>
Close the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/connect.html" title="basic_socket::connect"><span class="bold"><strong>connect</strong></span></a>
</p>
</td>
<td>
<p>
Connect the socket to the specified endpoint.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/get_executor.html" title="basic_socket::get_executor"><span class="bold"><strong>get_executor</strong></span></a>
</p>
</td>
<td>
<p>
Get the executor associated with the object.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/get_option.html" title="basic_socket::get_option"><span class="bold"><strong>get_option</strong></span></a>
</p>
</td>
<td>
<p>
Get an option from the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/io_control.html" title="basic_socket::io_control"><span class="bold"><strong>io_control</strong></span></a>
</p>
</td>
<td>
<p>
Perform an IO control command on the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/is_open.html" title="basic_socket::is_open"><span class="bold"><strong>is_open</strong></span></a>
</p>
</td>
<td>
<p>
Determine whether the socket is open.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/local_endpoint.html" title="basic_socket::local_endpoint"><span class="bold"><strong>local_endpoint</strong></span></a>
</p>
</td>
<td>
<p>
Get the local endpoint of the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/lowest_layer.html" title="basic_socket::lowest_layer"><span class="bold"><strong>lowest_layer</strong></span></a>
</p>
</td>
<td>
<p>
Get a reference to the lowest layer. <br> <span class="silver"></span><br> Get a const
reference to the lowest layer.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/native_handle.html" title="basic_socket::native_handle"><span class="bold"><strong>native_handle</strong></span></a>
</p>
</td>
<td>
<p>
Get the native socket representation.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/native_non_blocking.html" title="basic_socket::native_non_blocking"><span class="bold"><strong>native_non_blocking</strong></span></a>
</p>
</td>
<td>
<p>
Gets the non-blocking mode of the native socket implementation.
<br> <span class="silver"></span><br> Sets the non-blocking mode of the native socket
implementation.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/non_blocking.html" title="basic_socket::non_blocking"><span class="bold"><strong>non_blocking</strong></span></a>
</p>
</td>
<td>
<p>
Gets the non-blocking mode of the socket. <br> <span class="silver"></span><br> Sets
the non-blocking mode of the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/open.html" title="basic_socket::open"><span class="bold"><strong>open</strong></span></a>
</p>
</td>
<td>
<p>
Open the socket using the specified protocol.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/operator_eq_.html" title="basic_socket::operator="><span class="bold"><strong>operator=</strong></span></a>
</p>
</td>
<td>
<p>
Move-assign a basic_socket from another. <br> <span class="silver"></span><br> Move-assign
a basic_socket from a socket of another protocol type.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/release.html" title="basic_socket::release"><span class="bold"><strong>release</strong></span></a>
</p>
</td>
<td>
<p>
Release ownership of the underlying native socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/remote_endpoint.html" title="basic_socket::remote_endpoint"><span class="bold"><strong>remote_endpoint</strong></span></a>
</p>
</td>
<td>
<p>
Get the remote endpoint of the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/set_option.html" title="basic_socket::set_option"><span class="bold"><strong>set_option</strong></span></a>
</p>
</td>
<td>
<p>
Set an option on the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/shutdown.html" title="basic_socket::shutdown"><span class="bold"><strong>shutdown</strong></span></a>
</p>
</td>
<td>
<p>
Disable sends or receives on the socket.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/wait.html" title="basic_socket::wait"><span class="bold"><strong>wait</strong></span></a>
</p>
</td>
<td>
<p>
Wait for the socket to become ready to read, ready to write,
or to have pending error conditions.
</p>
</td>
</tr>
</tbody>
</table></div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.protected_member_functions"></a></span><a class="link" href="lowest_layer_type.html#boost_asio.reference.basic_stream_socket.lowest_layer_type.protected_member_functions">Protected
Member Functions</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
<th>
<p>
Name
</p>
</th>
<th>
<p>
Description
</p>
</th>
</tr></thead>
<tbody><tr>
<td>
<p>
<a class="link" href="../basic_socket/_basic_socket.html" title="basic_socket::~basic_socket"><span class="bold"><strong>~basic_socket</strong></span></a> <span class="silver">[destructor]</span>
</p>
</td>
<td>
<p>
Protected destructor to prevent deletion through this type.
</p>
</td>
</tr></tbody>
</table></div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.h3"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.data_members"></a></span><a class="link" href="lowest_layer_type.html#boost_asio.reference.basic_stream_socket.lowest_layer_type.data_members">Data
Members</a>
</h6>
<div class="informaltable"><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
<th>
<p>
Name
</p>
</th>
<th>
<p>
Description
</p>
</th>
</tr></thead>
<tbody>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/max_connections.html" title="basic_socket::max_connections"><span class="bold"><strong>max_connections</strong></span></a> <span class="silver">[static]</span>
</p>
</td>
<td>
<p>
(Deprecated: Use max_listen_connections.) The maximum length
of the queue of pending incoming connections.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/max_listen_connections.html" title="basic_socket::max_listen_connections"><span class="bold"><strong>max_listen_connections</strong></span></a> <span class="silver">[static]</span>
</p>
</td>
<td>
<p>
The maximum length of the queue of pending incoming connections.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/message_do_not_route.html" title="basic_socket::message_do_not_route"><span class="bold"><strong>message_do_not_route</strong></span></a> <span class="silver">[static]</span>
</p>
</td>
<td>
<p>
Specify that the data should not be subject to routing.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/message_end_of_record.html" title="basic_socket::message_end_of_record"><span class="bold"><strong>message_end_of_record</strong></span></a> <span class="silver">[static]</span>
</p>
</td>
<td>
<p>
Specifies that the data marks the end of a record.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/message_out_of_band.html" title="basic_socket::message_out_of_band"><span class="bold"><strong>message_out_of_band</strong></span></a> <span class="silver">[static]</span>
</p>
</td>
<td>
<p>
Process out-of-band data.
</p>
</td>
</tr>
<tr>
<td>
<p>
<a class="link" href="../basic_socket/message_peek.html" title="basic_socket::message_peek"><span class="bold"><strong>message_peek</strong></span></a> <span class="silver">[static]</span>
</p>
</td>
<td>
<p>
Peek at incoming data without removing it from the input queue.
</p>
</td>
</tr>
</tbody>
</table></div>
<p>
The <a class="link" href="../basic_socket.html" title="basic_socket"><code class="computeroutput">basic_socket</code></a>
class template provides functionality that is common to both stream-oriented
and datagram-oriented sockets.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.h4"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.thread_safety"></a></span><a class="link" href="lowest_layer_type.html#boost_asio.reference.basic_stream_socket.lowest_layer_type.thread_safety">Thread
Safety</a>
</h6>
<p>
<span class="emphasis"><em>Distinct</em></span> <span class="emphasis"><em>objects:</em></span> Safe.
</p>
<p>
<span class="emphasis"><em>Shared</em></span> <span class="emphasis"><em>objects:</em></span> Unsafe.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.h5"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.lowest_layer_type.requirements"></a></span><a class="link" href="lowest_layer_type.html#boost_asio.reference.basic_stream_socket.lowest_layer_type.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="lowest_layer/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="max_connections.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,55 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::max_connections</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="lowest_layer_type.html" title="basic_stream_socket::lowest_layer_type">
<link rel="next" href="max_listen_connections.html" title="basic_stream_socket::max_listen_connections">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="lowest_layer_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="max_listen_connections.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.max_connections"></a><a class="link" href="max_connections.html" title="basic_stream_socket::max_connections">basic_stream_socket::max_connections</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.max_connections"></a>
(Deprecated:
Use max_listen_connections.) The maximum length of the queue of pending
incoming connections.
</p>
<pre class="programlisting">static const int max_connections = implementation_defined;
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="lowest_layer_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="max_listen_connections.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,54 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::max_listen_connections</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="max_connections.html" title="basic_stream_socket::max_connections">
<link rel="next" href="message_do_not_route.html" title="basic_stream_socket::message_do_not_route">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="max_connections.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_do_not_route.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.max_listen_connections"></a><a class="link" href="max_listen_connections.html" title="basic_stream_socket::max_listen_connections">basic_stream_socket::max_listen_connections</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.max_listen_connections"></a>
The
maximum length of the queue of pending incoming connections.
</p>
<pre class="programlisting">static const int max_listen_connections = implementation_defined;
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="max_connections.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_do_not_route.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,54 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::message_do_not_route</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="max_listen_connections.html" title="basic_stream_socket::max_listen_connections">
<link rel="next" href="message_end_of_record.html" title="basic_stream_socket::message_end_of_record">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="max_listen_connections.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_end_of_record.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.message_do_not_route"></a><a class="link" href="message_do_not_route.html" title="basic_stream_socket::message_do_not_route">basic_stream_socket::message_do_not_route</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.message_do_not_route"></a>
Specify
that the data should not be subject to routing.
</p>
<pre class="programlisting">static const int message_do_not_route = implementation_defined;
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="max_listen_connections.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_end_of_record.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,54 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::message_end_of_record</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="message_do_not_route.html" title="basic_stream_socket::message_do_not_route">
<link rel="next" href="message_flags.html" title="basic_stream_socket::message_flags">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_do_not_route.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_flags.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.message_end_of_record"></a><a class="link" href="message_end_of_record.html" title="basic_stream_socket::message_end_of_record">basic_stream_socket::message_end_of_record</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.message_end_of_record"></a>
Specifies
that the data marks the end of a record.
</p>
<pre class="programlisting">static const int message_end_of_record = implementation_defined;
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_do_not_route.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_flags.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,64 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::message_flags</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="message_end_of_record.html" title="basic_stream_socket::message_end_of_record">
<link rel="next" href="message_out_of_band.html" title="basic_stream_socket::message_out_of_band">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_end_of_record.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_out_of_band.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.message_flags"></a><a class="link" href="message_flags.html" title="basic_stream_socket::message_flags">basic_stream_socket::message_flags</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.message_flags"></a>
Bitmask
type for flags that can be passed to send and receive operations.
</p>
<pre class="programlisting">typedef int message_flags;
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.message_flags.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.message_flags.requirements"></a></span><a class="link" href="message_flags.html#boost_asio.reference.basic_stream_socket.message_flags.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_end_of_record.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_out_of_band.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,54 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::message_out_of_band</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="message_flags.html" title="basic_stream_socket::message_flags">
<link rel="next" href="message_peek.html" title="basic_stream_socket::message_peek">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_flags.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_peek.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.message_out_of_band"></a><a class="link" href="message_out_of_band.html" title="basic_stream_socket::message_out_of_band">basic_stream_socket::message_out_of_band</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.message_out_of_band"></a>
Process
out-of-band data.
</p>
<pre class="programlisting">static const int message_out_of_band = implementation_defined;
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_flags.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="message_peek.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,54 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::message_peek</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="message_out_of_band.html" title="basic_stream_socket::message_out_of_band">
<link rel="next" href="native_handle.html" title="basic_stream_socket::native_handle">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_out_of_band.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="native_handle.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.message_peek"></a><a class="link" href="message_peek.html" title="basic_stream_socket::message_peek">basic_stream_socket::message_peek</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.message_peek"></a>
Peek
at incoming data without removing it from the input queue.
</p>
<pre class="programlisting">static const int message_peek = implementation_defined;
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_out_of_band.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="native_handle.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,59 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::native_handle</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="message_peek.html" title="basic_stream_socket::message_peek">
<link rel="next" href="native_handle_type.html" title="basic_stream_socket::native_handle_type">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_peek.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="native_handle_type.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.native_handle"></a><a class="link" href="native_handle.html" title="basic_stream_socket::native_handle">basic_stream_socket::native_handle</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.native_handle"></a>
Get
the native socket representation.
</p>
<pre class="programlisting">native_handle_type native_handle();
</pre>
<p>
This function may be used to obtain the underlying representation of the
socket. This is intended to allow access to native socket functionality
that is not otherwise provided.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="message_peek.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="native_handle_type.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,61 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::native_handle_type</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="native_handle.html" title="basic_stream_socket::native_handle">
<link rel="next" href="native_non_blocking.html" title="basic_stream_socket::native_non_blocking">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="native_handle.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="native_non_blocking.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.native_handle_type"></a><a class="link" href="native_handle_type.html" title="basic_stream_socket::native_handle_type">basic_stream_socket::native_handle_type</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.native_handle_type"></a>
The
native representation of a socket.
</p>
<pre class="programlisting">typedef implementation_defined native_handle_type;
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_handle_type.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_handle_type.requirements"></a></span><a class="link" href="native_handle_type.html#boost_asio.reference.basic_stream_socket.native_handle_type.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="native_handle.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="native_non_blocking.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,64 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::native_non_blocking</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="native_handle_type.html" title="basic_stream_socket::native_handle_type">
<link rel="next" href="native_non_blocking/overload1.html" title="basic_stream_socket::native_non_blocking (1 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="native_handle_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="native_non_blocking/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking"></a><a class="link" href="native_non_blocking.html" title="basic_stream_socket::native_non_blocking">basic_stream_socket::native_non_blocking</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.native_non_blocking"></a>
Gets
the non-blocking mode of the native socket implementation.
</p>
<pre class="programlisting">bool <a class="link" href="native_non_blocking/overload1.html" title="basic_stream_socket::native_non_blocking (1 of 3 overloads)">native_non_blocking</a>() const;
<span class="emphasis"><em>» <a class="link" href="native_non_blocking/overload1.html" title="basic_stream_socket::native_non_blocking (1 of 3 overloads)">more...</a></em></span>
</pre>
<p>
Sets the non-blocking mode of the native socket implementation.
</p>
<pre class="programlisting">void <a class="link" href="native_non_blocking/overload2.html" title="basic_stream_socket::native_non_blocking (2 of 3 overloads)">native_non_blocking</a>(
bool mode);
<span class="emphasis"><em>» <a class="link" href="native_non_blocking/overload2.html" title="basic_stream_socket::native_non_blocking (2 of 3 overloads)">more...</a></em></span>
void <a class="link" href="native_non_blocking/overload3.html" title="basic_stream_socket::native_non_blocking (3 of 3 overloads)">native_non_blocking</a>(
bool mode,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="native_non_blocking/overload3.html" title="basic_stream_socket::native_non_blocking (3 of 3 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="native_handle_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="native_non_blocking/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,152 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::native_non_blocking (1 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../native_non_blocking.html" title="basic_stream_socket::native_non_blocking">
<link rel="prev" href="../native_non_blocking.html" title="basic_stream_socket::native_non_blocking">
<link rel="next" href="overload2.html" title="basic_stream_socket::native_non_blocking (2 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../native_non_blocking.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../native_non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::native_non_blocking (1 of 3 overloads)">basic_stream_socket::native_non_blocking
(1 of 3 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Gets the non-blocking mode of the native socket implementation.
</p>
<pre class="programlisting">bool native_non_blocking() const;
</pre>
<p>
This function is used to retrieve the non-blocking mode of the underlying
native socket. This mode has no effect on the behaviour of the socket
object's synchronous operations.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.return_value"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.return_value">Return
Value</a>
</h6>
<p>
<code class="computeroutput">true</code> if the underlying socket is in non-blocking mode and
direct system calls may fail with <code class="computeroutput">boost::asio::error::would_block</code>
(or the equivalent system error).
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.remarks">Remarks</a>
</h6>
<p>
The current non-blocking mode is cached by the socket object. Consequently,
the return value may be incorrect if the non-blocking mode was set directly
on the native socket.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.native_non_blocking.overload1.example">Example</a>
</h6>
<p>
This function is intended to allow the encapsulation of arbitrary non-blocking
system calls as asynchronous operations, in a way that is transparent
to the user of the socket object. The following example illustrates how
Linux's <code class="computeroutput">sendfile</code> system call might be encapsulated:
</p>
<pre class="programlisting">template &lt;typename Handler&gt;
struct sendfile_op
{
tcp::socket&amp; sock_;
int fd_;
Handler handler_;
off_t offset_;
std::size_t total_bytes_transferred_;
// Function call operator meeting WriteHandler requirements.
// Used as the handler for the async_write_some operation.
void operator()(boost::system::error_code ec, std::size_t)
{
// Put the underlying socket into non-blocking mode.
if (!ec)
if (!sock_.native_non_blocking())
sock_.native_non_blocking(true, ec);
if (!ec)
{
for (;;)
{
// Try the system call.
errno = 0;
int n = ::sendfile(sock_.native_handle(), fd_, &amp;offset_, 65536);
ec = boost::system::error_code(n &lt; 0 ? errno : 0,
boost::asio::error::get_system_category());
total_bytes_transferred_ += ec ? 0 : n;
// Retry operation immediately if interrupted by signal.
if (ec == boost::asio::error::interrupted)
continue;
// Check if we need to run the operation again.
if (ec == boost::asio::error::would_block
|| ec == boost::asio::error::try_again)
{
// We have to wait for the socket to become ready again.
sock_.async_wait(tcp::socket::wait_write, *this);
return;
}
if (ec || n == 0)
{
// An error occurred, or we have reached the end of the file.
// Either way we must exit the loop so we can call the handler.
break;
}
// Loop around to try calling sendfile again.
}
}
// Pass result back to user's handler.
handler_(ec, total_bytes_transferred_);
}
};
template &lt;typename Handler&gt;
void async_sendfile(tcp::socket&amp; sock, int fd, Handler h)
{
sendfile_op&lt;Handler&gt; op = { sock, fd, h, 0, 0 };
sock.async_wait(tcp::socket::wait_write, op);
}
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../native_non_blocking.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../native_non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,165 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::native_non_blocking (2 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../native_non_blocking.html" title="basic_stream_socket::native_non_blocking">
<link rel="prev" href="overload1.html" title="basic_stream_socket::native_non_blocking (1 of 3 overloads)">
<link rel="next" href="overload3.html" title="basic_stream_socket::native_non_blocking (3 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../native_non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload3.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::native_non_blocking (2 of 3 overloads)">basic_stream_socket::native_non_blocking
(2 of 3 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Sets the non-blocking mode of the native socket implementation.
</p>
<pre class="programlisting">void native_non_blocking(
bool mode);
</pre>
<p>
This function is used to modify the non-blocking mode of the underlying
native socket. It has no effect on the behaviour of the socket object's
synchronous operations.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">mode</span></dt>
<dd><p>
If <code class="computeroutput">true</code>, the underlying socket is put into non-blocking
mode and direct system calls may fail with <code class="computeroutput">boost::asio::error::would_block</code>
(or the equivalent system error).
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.exceptions"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure. If the <code class="computeroutput">mode</code> is <code class="computeroutput">false</code>,
but the current value of <code class="computeroutput">non_blocking()</code> is <code class="computeroutput">true</code>,
this function fails with <code class="computeroutput">boost::asio::error::invalid_argument</code>,
as the combination does not make sense.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.native_non_blocking.overload2.example">Example</a>
</h6>
<p>
This function is intended to allow the encapsulation of arbitrary non-blocking
system calls as asynchronous operations, in a way that is transparent
to the user of the socket object. The following example illustrates how
Linux's <code class="computeroutput">sendfile</code> system call might be encapsulated:
</p>
<pre class="programlisting">template &lt;typename Handler&gt;
struct sendfile_op
{
tcp::socket&amp; sock_;
int fd_;
Handler handler_;
off_t offset_;
std::size_t total_bytes_transferred_;
// Function call operator meeting WriteHandler requirements.
// Used as the handler for the async_write_some operation.
void operator()(boost::system::error_code ec, std::size_t)
{
// Put the underlying socket into non-blocking mode.
if (!ec)
if (!sock_.native_non_blocking())
sock_.native_non_blocking(true, ec);
if (!ec)
{
for (;;)
{
// Try the system call.
errno = 0;
int n = ::sendfile(sock_.native_handle(), fd_, &amp;offset_, 65536);
ec = boost::system::error_code(n &lt; 0 ? errno : 0,
boost::asio::error::get_system_category());
total_bytes_transferred_ += ec ? 0 : n;
// Retry operation immediately if interrupted by signal.
if (ec == boost::asio::error::interrupted)
continue;
// Check if we need to run the operation again.
if (ec == boost::asio::error::would_block
|| ec == boost::asio::error::try_again)
{
// We have to wait for the socket to become ready again.
sock_.async_wait(tcp::socket::wait_write, *this);
return;
}
if (ec || n == 0)
{
// An error occurred, or we have reached the end of the file.
// Either way we must exit the loop so we can call the handler.
break;
}
// Loop around to try calling sendfile again.
}
}
// Pass result back to user's handler.
handler_(ec, total_bytes_transferred_);
}
};
template &lt;typename Handler&gt;
void async_sendfile(tcp::socket&amp; sock, int fd, Handler h)
{
sendfile_op&lt;Handler&gt; op = { sock, fd, h, 0, 0 };
sock.async_wait(tcp::socket::wait_write, op);
}
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../native_non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload3.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,157 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::native_non_blocking (3 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../native_non_blocking.html" title="basic_stream_socket::native_non_blocking">
<link rel="prev" href="overload2.html" title="basic_stream_socket::native_non_blocking (2 of 3 overloads)">
<link rel="next" href="../non_blocking.html" title="basic_stream_socket::non_blocking">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload2.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../native_non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../non_blocking.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload3"></a><a class="link" href="overload3.html" title="basic_stream_socket::native_non_blocking (3 of 3 overloads)">basic_stream_socket::native_non_blocking
(3 of 3 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Sets the non-blocking mode of the native socket implementation.
</p>
<pre class="programlisting">void native_non_blocking(
bool mode,
boost::system::error_code &amp; ec);
</pre>
<p>
This function is used to modify the non-blocking mode of the underlying
native socket. It has no effect on the behaviour of the socket object's
synchronous operations.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload3.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload3.parameters"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.native_non_blocking.overload3.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">mode</span></dt>
<dd><p>
If <code class="computeroutput">true</code>, the underlying socket is put into non-blocking
mode and direct system calls may fail with <code class="computeroutput">boost::asio::error::would_block</code>
(or the equivalent system error).
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any. If the <code class="computeroutput">mode</code>
is <code class="computeroutput">false</code>, but the current value of <code class="computeroutput">non_blocking()</code>
is <code class="computeroutput">true</code>, this function fails with <code class="computeroutput">boost::asio::error::invalid_argument</code>,
as the combination does not make sense.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload3.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.native_non_blocking.overload3.example"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.native_non_blocking.overload3.example">Example</a>
</h6>
<p>
This function is intended to allow the encapsulation of arbitrary non-blocking
system calls as asynchronous operations, in a way that is transparent
to the user of the socket object. The following example illustrates how
Linux's <code class="computeroutput">sendfile</code> system call might be encapsulated:
</p>
<pre class="programlisting">template &lt;typename Handler&gt;
struct sendfile_op
{
tcp::socket&amp; sock_;
int fd_;
Handler handler_;
off_t offset_;
std::size_t total_bytes_transferred_;
// Function call operator meeting WriteHandler requirements.
// Used as the handler for the async_write_some operation.
void operator()(boost::system::error_code ec, std::size_t)
{
// Put the underlying socket into non-blocking mode.
if (!ec)
if (!sock_.native_non_blocking())
sock_.native_non_blocking(true, ec);
if (!ec)
{
for (;;)
{
// Try the system call.
errno = 0;
int n = ::sendfile(sock_.native_handle(), fd_, &amp;offset_, 65536);
ec = boost::system::error_code(n &lt; 0 ? errno : 0,
boost::asio::error::get_system_category());
total_bytes_transferred_ += ec ? 0 : n;
// Retry operation immediately if interrupted by signal.
if (ec == boost::asio::error::interrupted)
continue;
// Check if we need to run the operation again.
if (ec == boost::asio::error::would_block
|| ec == boost::asio::error::try_again)
{
// We have to wait for the socket to become ready again.
sock_.async_wait(tcp::socket::wait_write, *this);
return;
}
if (ec || n == 0)
{
// An error occurred, or we have reached the end of the file.
// Either way we must exit the loop so we can call the handler.
break;
}
// Loop around to try calling sendfile again.
}
}
// Pass result back to user's handler.
handler_(ec, total_bytes_transferred_);
}
};
template &lt;typename Handler&gt;
void async_sendfile(tcp::socket&amp; sock, int fd, Handler h)
{
sendfile_op&lt;Handler&gt; op = { sock, fd, h, 0, 0 };
sock.async_wait(tcp::socket::wait_write, op);
}
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload2.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../native_non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../non_blocking.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,64 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::non_blocking</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="native_non_blocking/overload3.html" title="basic_stream_socket::native_non_blocking (3 of 3 overloads)">
<link rel="next" href="non_blocking/overload1.html" title="basic_stream_socket::non_blocking (1 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="native_non_blocking/overload3.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="non_blocking/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.non_blocking"></a><a class="link" href="non_blocking.html" title="basic_stream_socket::non_blocking">basic_stream_socket::non_blocking</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.non_blocking"></a>
Gets
the non-blocking mode of the socket.
</p>
<pre class="programlisting">bool <a class="link" href="non_blocking/overload1.html" title="basic_stream_socket::non_blocking (1 of 3 overloads)">non_blocking</a>() const;
<span class="emphasis"><em>» <a class="link" href="non_blocking/overload1.html" title="basic_stream_socket::non_blocking (1 of 3 overloads)">more...</a></em></span>
</pre>
<p>
Sets the non-blocking mode of the socket.
</p>
<pre class="programlisting">void <a class="link" href="non_blocking/overload2.html" title="basic_stream_socket::non_blocking (2 of 3 overloads)">non_blocking</a>(
bool mode);
<span class="emphasis"><em>» <a class="link" href="non_blocking/overload2.html" title="basic_stream_socket::non_blocking (2 of 3 overloads)">more...</a></em></span>
void <a class="link" href="non_blocking/overload3.html" title="basic_stream_socket::non_blocking (3 of 3 overloads)">non_blocking</a>(
bool mode,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="non_blocking/overload3.html" title="basic_stream_socket::non_blocking (3 of 3 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="native_non_blocking/overload3.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="non_blocking/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,72 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::non_blocking (1 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../non_blocking.html" title="basic_stream_socket::non_blocking">
<link rel="prev" href="../non_blocking.html" title="basic_stream_socket::non_blocking">
<link rel="next" href="overload2.html" title="basic_stream_socket::non_blocking (2 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../non_blocking.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::non_blocking (1 of 3 overloads)">basic_stream_socket::non_blocking
(1 of 3 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Gets the non-blocking mode of the socket.
</p>
<pre class="programlisting">bool non_blocking() const;
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.non_blocking.overload1.return_value"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.non_blocking.overload1.return_value">Return
Value</a>
</h6>
<p>
<code class="computeroutput">true</code> if the socket's synchronous operations will fail with
<code class="computeroutput">boost::asio::error::would_block</code> if they are unable to perform
the requested operation immediately. If <code class="computeroutput">false</code>, synchronous
operations will block until complete.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.non_blocking.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.non_blocking.overload1.remarks">Remarks</a>
</h6>
<p>
The non-blocking mode has no effect on the behaviour of asynchronous
operations. Asynchronous operations will never fail with the error <code class="computeroutput">boost::asio::error::would_block</code>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../non_blocking.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,91 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::non_blocking (2 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../non_blocking.html" title="basic_stream_socket::non_blocking">
<link rel="prev" href="overload1.html" title="basic_stream_socket::non_blocking (1 of 3 overloads)">
<link rel="next" href="overload3.html" title="basic_stream_socket::non_blocking (3 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload3.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::non_blocking (2 of 3 overloads)">basic_stream_socket::non_blocking
(2 of 3 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Sets the non-blocking mode of the socket.
</p>
<pre class="programlisting">void non_blocking(
bool mode);
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.non_blocking.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.non_blocking.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">mode</span></dt>
<dd><p>
If <code class="computeroutput">true</code>, the socket's synchronous operations will
fail with <code class="computeroutput">boost::asio::error::would_block</code> if they
are unable to perform the requested operation immediately. If
<code class="computeroutput">false</code>, synchronous operations will block until complete.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.non_blocking.overload2.exceptions"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.non_blocking.overload2.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload2.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.non_blocking.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.non_blocking.overload2.remarks">Remarks</a>
</h6>
<p>
The non-blocking mode has no effect on the behaviour of asynchronous
operations. Asynchronous operations will never fail with the error <code class="computeroutput">boost::asio::error::would_block</code>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload3.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,83 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::non_blocking (3 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../non_blocking.html" title="basic_stream_socket::non_blocking">
<link rel="prev" href="overload2.html" title="basic_stream_socket::non_blocking (2 of 3 overloads)">
<link rel="next" href="../open.html" title="basic_stream_socket::open">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload2.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../open.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload3"></a><a class="link" href="overload3.html" title="basic_stream_socket::non_blocking (3 of 3 overloads)">basic_stream_socket::non_blocking
(3 of 3 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Sets the non-blocking mode of the socket.
</p>
<pre class="programlisting">void non_blocking(
bool mode,
boost::system::error_code &amp; ec);
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload3.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.non_blocking.overload3.parameters"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.non_blocking.overload3.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">mode</span></dt>
<dd><p>
If <code class="computeroutput">true</code>, the socket's synchronous operations will
fail with <code class="computeroutput">boost::asio::error::would_block</code> if they
are unable to perform the requested operation immediately. If
<code class="computeroutput">false</code>, synchronous operations will block until complete.
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.non_blocking.overload3.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.non_blocking.overload3.remarks"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.non_blocking.overload3.remarks">Remarks</a>
</h6>
<p>
The non-blocking mode has no effect on the behaviour of asynchronous
operations. Asynchronous operations will never fail with the error <code class="computeroutput">boost::asio::error::would_block</code>.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload2.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../non_blocking.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../open.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,58 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::open</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="non_blocking/overload3.html" title="basic_stream_socket::non_blocking (3 of 3 overloads)">
<link rel="next" href="open/overload1.html" title="basic_stream_socket::open (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="non_blocking/overload3.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="open/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.open"></a><a class="link" href="open.html" title="basic_stream_socket::open">basic_stream_socket::open</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.open"></a>
Open
the socket using the specified protocol.
</p>
<pre class="programlisting">void <a class="link" href="open/overload1.html" title="basic_stream_socket::open (1 of 2 overloads)">open</a>(
const protocol_type &amp; protocol = protocol_type());
<span class="emphasis"><em>» <a class="link" href="open/overload1.html" title="basic_stream_socket::open (1 of 2 overloads)">more...</a></em></span>
void <a class="link" href="open/overload2.html" title="basic_stream_socket::open (2 of 2 overloads)">open</a>(
const protocol_type &amp; protocol,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="open/overload2.html" title="basic_stream_socket::open (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="non_blocking/overload3.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="open/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,90 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::open (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../open.html" title="basic_stream_socket::open">
<link rel="prev" href="../open.html" title="basic_stream_socket::open">
<link rel="next" href="overload2.html" title="basic_stream_socket::open (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../open.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../open.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.open.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::open (1 of 2 overloads)">basic_stream_socket::open
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Open the socket using the specified protocol.
</p>
<pre class="programlisting">void open(
const protocol_type &amp; protocol = protocol_type());
</pre>
<p>
This function opens the socket so that it will use the specified protocol.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.open.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.open.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.open.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">protocol</span></dt>
<dd><p>
An object specifying protocol parameters to be used.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.open.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.open.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.open.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.open.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.open.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.open.overload1.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
socket.open(boost::asio::ip::tcp::v4());
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../open.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../open.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,87 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::open (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../open.html" title="basic_stream_socket::open">
<link rel="prev" href="overload1.html" title="basic_stream_socket::open (1 of 2 overloads)">
<link rel="next" href="../operator_eq_.html" title="basic_stream_socket::operator=">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../open.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../operator_eq_.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.open.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::open (2 of 2 overloads)">basic_stream_socket::open
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
<span class="emphasis"><em>Inherited from basic_socket.</em></span>
</p>
<p>
Open the socket using the specified protocol.
</p>
<pre class="programlisting">void open(
const protocol_type &amp; protocol,
boost::system::error_code &amp; ec);
</pre>
<p>
This function opens the socket so that it will use the specified protocol.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.open.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.open.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.open.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">protocol</span></dt>
<dd><p>
An object specifying which protocol is to be used.
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.open.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.open.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.open.overload2.example">Example</a>
</h6>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
boost::system::error_code ec;
socket.open(boost::asio::ip::tcp::v4(), ec);
if (ec)
{
// An error occurred.
}
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../open.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../operator_eq_.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,65 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::operator=</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="open/overload2.html" title="basic_stream_socket::open (2 of 2 overloads)">
<link rel="next" href="operator_eq_/overload1.html" title="basic_stream_socket::operator= (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="open/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="operator_eq_/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.operator_eq_"></a><a class="link" href="operator_eq_.html" title="basic_stream_socket::operator=">basic_stream_socket::operator=</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.operator_eq_"></a>
Move-assign
a <a class="link" href="../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
from another.
</p>
<pre class="programlisting">basic_stream_socket &amp; <a class="link" href="operator_eq_/overload1.html" title="basic_stream_socket::operator= (1 of 2 overloads)">operator=</a>(
basic_stream_socket &amp;&amp; other);
<span class="emphasis"><em>» <a class="link" href="operator_eq_/overload1.html" title="basic_stream_socket::operator= (1 of 2 overloads)">more...</a></em></span>
</pre>
<p>
Move-assign a <a class="link" href="../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
from a socket of another protocol type.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../Protocol.html" title="Protocol requirements">Protocol1</a>,
typename <a class="link" href="../Executor1.html" title="Executor requirements">Executor1</a>&gt;
constraint&lt; is_convertible&lt; Protocol1, Protocol &gt;::value &amp;&amp;is_convertible&lt; Executor1, Executor &gt;::value, basic_stream_socket &amp; &gt;::type <a class="link" href="operator_eq_/overload2.html" title="basic_stream_socket::operator= (2 of 2 overloads)">operator=</a>(
basic_stream_socket&lt; Protocol1, Executor1 &gt; &amp;&amp; other);
<span class="emphasis"><em>» <a class="link" href="operator_eq_/overload2.html" title="basic_stream_socket::operator= (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="open/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="operator_eq_/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,78 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::operator= (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../operator_eq_.html" title="basic_stream_socket::operator=">
<link rel="prev" href="../operator_eq_.html" title="basic_stream_socket::operator=">
<link rel="next" href="overload2.html" title="basic_stream_socket::operator= (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../operator_eq_.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator_eq_.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::operator= (1 of 2 overloads)">basic_stream_socket::operator=
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
Move-assign a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
from another.
</p>
<pre class="programlisting">basic_stream_socket &amp; operator=(
basic_stream_socket &amp;&amp; other);
</pre>
<p>
This assignment operator moves a stream socket from one object to another.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.operator_eq_.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">other</span></dt>
<dd><p>
The other <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
object from which the move will occur.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.operator_eq_.overload1.remarks">Remarks</a>
</h6>
<p>
Following the move, the moved-from object is in the same state as if
constructed using the <code class="computeroutput">basic_stream_socket(const executor_type&amp;)</code>
constructor.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../operator_eq_.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator_eq_.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,81 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::operator= (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../operator_eq_.html" title="basic_stream_socket::operator=">
<link rel="prev" href="overload1.html" title="basic_stream_socket::operator= (1 of 2 overloads)">
<link rel="next" href="../out_of_band_inline.html" title="basic_stream_socket::out_of_band_inline">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator_eq_.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../out_of_band_inline.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::operator= (2 of 2 overloads)">basic_stream_socket::operator=
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
Move-assign a <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
from a socket of another protocol type.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../Protocol.html" title="Protocol requirements">Protocol1</a>,
typename <a class="link" href="../../Executor1.html" title="Executor requirements">Executor1</a>&gt;
constraint&lt; is_convertible&lt; Protocol1, Protocol &gt;::value &amp;&amp;is_convertible&lt; Executor1, Executor &gt;::value, basic_stream_socket &amp; &gt;::type operator=(
basic_stream_socket&lt; Protocol1, Executor1 &gt; &amp;&amp; other);
</pre>
<p>
This assignment operator moves a stream socket from one object to another.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.operator_eq_.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">other</span></dt>
<dd><p>
The other <a class="link" href="../../basic_stream_socket.html" title="basic_stream_socket"><code class="computeroutput">basic_stream_socket</code></a>
object from which the move will occur.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.operator_eq_.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.operator_eq_.overload2.remarks">Remarks</a>
</h6>
<p>
Following the move, the moved-from object is in the same state as if
constructed using the <code class="computeroutput">basic_stream_socket(const executor_type&amp;)</code>
constructor.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../operator_eq_.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../out_of_band_inline.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,88 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::out_of_band_inline</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="operator_eq_/overload2.html" title="basic_stream_socket::operator= (2 of 2 overloads)">
<link rel="next" href="protocol_type.html" title="basic_stream_socket::protocol_type">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="operator_eq_/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="protocol_type.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.out_of_band_inline"></a><a class="link" href="out_of_band_inline.html" title="basic_stream_socket::out_of_band_inline">basic_stream_socket::out_of_band_inline</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.out_of_band_inline"></a>
Socket
option for putting received out-of-band data inline.
</p>
<pre class="programlisting">typedef implementation_defined out_of_band_inline;
</pre>
<p>
Implements the SOL_SOCKET/SO_OOBINLINE socket option.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.out_of_band_inline.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.out_of_band_inline.examples"></a></span><a class="link" href="out_of_band_inline.html#boost_asio.reference.basic_stream_socket.out_of_band_inline.examples">Examples</a>
</h6>
<p>
Setting the option:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::out_of_band_inline option(true);
socket.set_option(option);
</pre>
<p>
Getting the current option value:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::out_of_band_inline option;
socket.get_option(option);
bool value = option.value();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.out_of_band_inline.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.out_of_band_inline.requirements"></a></span><a class="link" href="out_of_band_inline.html#boost_asio.reference.basic_stream_socket.out_of_band_inline.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="operator_eq_/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="protocol_type.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,61 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::protocol_type</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="out_of_band_inline.html" title="basic_stream_socket::out_of_band_inline">
<link rel="next" href="read_some.html" title="basic_stream_socket::read_some">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="out_of_band_inline.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="read_some.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.protocol_type"></a><a class="link" href="protocol_type.html" title="basic_stream_socket::protocol_type">basic_stream_socket::protocol_type</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.protocol_type"></a>
The
protocol type.
</p>
<pre class="programlisting">typedef Protocol protocol_type;
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.protocol_type.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.protocol_type.requirements"></a></span><a class="link" href="protocol_type.html#boost_asio.reference.basic_stream_socket.protocol_type.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="out_of_band_inline.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="read_some.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,62 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::read_some</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="protocol_type.html" title="basic_stream_socket::protocol_type">
<link rel="next" href="read_some/overload1.html" title="basic_stream_socket::read_some (1 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="protocol_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="read_some/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.read_some"></a><a class="link" href="read_some.html" title="basic_stream_socket::read_some">basic_stream_socket::read_some</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.read_some"></a>
Read
some data from the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t <a class="link" href="read_some/overload1.html" title="basic_stream_socket::read_some (1 of 2 overloads)">read_some</a>(
const MutableBufferSequence &amp; buffers);
<span class="emphasis"><em>» <a class="link" href="read_some/overload1.html" title="basic_stream_socket::read_some (1 of 2 overloads)">more...</a></em></span>
template&lt;
typename <a class="link" href="../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t <a class="link" href="read_some/overload2.html" title="basic_stream_socket::read_some (2 of 2 overloads)">read_some</a>(
const MutableBufferSequence &amp; buffers,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="read_some/overload2.html" title="basic_stream_socket::read_some (2 of 2 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="protocol_type.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="read_some/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,118 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::read_some (1 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../read_some.html" title="basic_stream_socket::read_some">
<link rel="prev" href="../read_some.html" title="basic_stream_socket::read_some">
<link rel="next" href="overload2.html" title="basic_stream_socket::read_some (2 of 2 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../read_some.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../read_some.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.read_some.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::read_some (1 of 2 overloads)">basic_stream_socket::read_some
(1 of 2 overloads)</a>
</h5></div></div></div>
<p>
Read some data from the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t read_some(
const MutableBufferSequence &amp; buffers);
</pre>
<p>
This function is used to read data from the stream socket. The function
call will block until one or more bytes of data has been read successfully,
or until an error occurs.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.read_some.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.read_some.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.read_some.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more buffers into which the data will be read.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.read_some.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.read_some.overload1.return_value"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.read_some.overload1.return_value">Return
Value</a>
</h6>
<p>
The number of bytes read.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.read_some.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.read_some.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.read_some.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure. An error code of <code class="computeroutput">boost::asio::error::eof</code>
indicates that the connection was closed by the peer.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.read_some.overload1.h3"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.read_some.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.read_some.overload1.remarks">Remarks</a>
</h6>
<p>
The read_some operation may not read all of the requested number of bytes.
Consider using the <a class="link" href="../../read.html" title="read"><code class="computeroutput">read</code></a>
function if you need to ensure that the requested amount of data is read
before the blocking operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.read_some.overload1.h4"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.read_some.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.read_some.overload1.example">Example</a>
</h6>
<p>
To read into a single data buffer use the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.read_some(boost::asio::buffer(data, size));
</pre>
<p>
See the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on reading into multiple buffers in one
go, and how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../read_some.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../read_some.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,94 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::read_some (2 of 2 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../read_some.html" title="basic_stream_socket::read_some">
<link rel="prev" href="overload1.html" title="basic_stream_socket::read_some (1 of 2 overloads)">
<link rel="next" href="../receive.html" title="basic_stream_socket::receive">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../read_some.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../receive.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.read_some.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::read_some (2 of 2 overloads)">basic_stream_socket::read_some
(2 of 2 overloads)</a>
</h5></div></div></div>
<p>
Read some data from the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t read_some(
const MutableBufferSequence &amp; buffers,
boost::system::error_code &amp; ec);
</pre>
<p>
This function is used to read data from the stream socket. The function
call will block until one or more bytes of data has been read successfully,
or until an error occurs.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.read_some.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.read_some.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.read_some.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more buffers into which the data will be read.
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.read_some.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.read_some.overload2.return_value"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.read_some.overload2.return_value">Return
Value</a>
</h6>
<p>
The number of bytes read. Returns 0 if an error occurred.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.read_some.overload2.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.read_some.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.read_some.overload2.remarks">Remarks</a>
</h6>
<p>
The read_some operation may not read all of the requested number of bytes.
Consider using the <a class="link" href="../../read.html" title="read"><code class="computeroutput">read</code></a>
function if you need to ensure that the requested amount of data is read
before the blocking operation completes.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../read_some.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../receive.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,73 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::receive</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="read_some/overload2.html" title="basic_stream_socket::read_some (2 of 2 overloads)">
<link rel="next" href="receive/overload1.html" title="basic_stream_socket::receive (1 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="read_some/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="receive/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.receive"></a><a class="link" href="receive.html" title="basic_stream_socket::receive">basic_stream_socket::receive</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.receive"></a>
Receive
some data on the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t <a class="link" href="receive/overload1.html" title="basic_stream_socket::receive (1 of 3 overloads)">receive</a>(
const MutableBufferSequence &amp; buffers);
<span class="emphasis"><em>» <a class="link" href="receive/overload1.html" title="basic_stream_socket::receive (1 of 3 overloads)">more...</a></em></span>
template&lt;
typename <a class="link" href="../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t <a class="link" href="receive/overload2.html" title="basic_stream_socket::receive (2 of 3 overloads)">receive</a>(
const MutableBufferSequence &amp; buffers,
socket_base::message_flags flags);
<span class="emphasis"><em>» <a class="link" href="receive/overload2.html" title="basic_stream_socket::receive (2 of 3 overloads)">more...</a></em></span>
</pre>
<p>
Receive some data on a connected socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t <a class="link" href="receive/overload3.html" title="basic_stream_socket::receive (3 of 3 overloads)">receive</a>(
const MutableBufferSequence &amp; buffers,
socket_base::message_flags flags,
boost::system::error_code &amp; ec);
<span class="emphasis"><em>» <a class="link" href="receive/overload3.html" title="basic_stream_socket::receive (3 of 3 overloads)">more...</a></em></span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="read_some/overload2.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="receive/overload1.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,118 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::receive (1 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../receive.html" title="basic_stream_socket::receive">
<link rel="prev" href="../receive.html" title="basic_stream_socket::receive">
<link rel="next" href="overload2.html" title="basic_stream_socket::receive (2 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../receive.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.receive.overload1"></a><a class="link" href="overload1.html" title="basic_stream_socket::receive (1 of 3 overloads)">basic_stream_socket::receive
(1 of 3 overloads)</a>
</h5></div></div></div>
<p>
Receive some data on the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t receive(
const MutableBufferSequence &amp; buffers);
</pre>
<p>
This function is used to receive data on the stream socket. The function
call will block until one or more bytes of data has been received successfully,
or until an error occurs.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload1.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload1.parameters"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.receive.overload1.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more buffers into which the data will be received.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload1.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload1.return_value"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.receive.overload1.return_value">Return
Value</a>
</h6>
<p>
The number of bytes received.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload1.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload1.exceptions"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.receive.overload1.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure. An error code of <code class="computeroutput">boost::asio::error::eof</code>
indicates that the connection was closed by the peer.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload1.h3"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload1.remarks"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.receive.overload1.remarks">Remarks</a>
</h6>
<p>
The receive operation may not receive all of the requested number of
bytes. Consider using the <a class="link" href="../../read.html" title="read"><code class="computeroutput">read</code></a>
function if you need to ensure that the requested amount of data is read
before the blocking operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload1.h4"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload1.example"></a></span><a class="link" href="overload1.html#boost_asio.reference.basic_stream_socket.receive.overload1.example">Example</a>
</h6>
<p>
To receive into a single data buffer use the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.receive(boost::asio::buffer(data, size));
</pre>
<p>
See the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on receiving into multiple buffers in one
go, and how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../receive.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload2.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,123 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::receive (2 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../receive.html" title="basic_stream_socket::receive">
<link rel="prev" href="overload1.html" title="basic_stream_socket::receive (1 of 3 overloads)">
<link rel="next" href="overload3.html" title="basic_stream_socket::receive (3 of 3 overloads)">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload3.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.receive.overload2"></a><a class="link" href="overload2.html" title="basic_stream_socket::receive (2 of 3 overloads)">basic_stream_socket::receive
(2 of 3 overloads)</a>
</h5></div></div></div>
<p>
Receive some data on the socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t receive(
const MutableBufferSequence &amp; buffers,
socket_base::message_flags flags);
</pre>
<p>
This function is used to receive data on the stream socket. The function
call will block until one or more bytes of data has been received successfully,
or until an error occurs.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload2.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload2.parameters"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.receive.overload2.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more buffers into which the data will be received.
</p></dd>
<dt><span class="term">flags</span></dt>
<dd><p>
Flags specifying how the receive call is to be made.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload2.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload2.return_value"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.receive.overload2.return_value">Return
Value</a>
</h6>
<p>
The number of bytes received.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload2.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload2.exceptions"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.receive.overload2.exceptions">Exceptions</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">boost::system::system_error</span></dt>
<dd><p>
Thrown on failure. An error code of <code class="computeroutput">boost::asio::error::eof</code>
indicates that the connection was closed by the peer.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload2.h3"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload2.remarks"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.receive.overload2.remarks">Remarks</a>
</h6>
<p>
The receive operation may not receive all of the requested number of
bytes. Consider using the <a class="link" href="../../read.html" title="read"><code class="computeroutput">read</code></a>
function if you need to ensure that the requested amount of data is read
before the blocking operation completes.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload2.h4"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload2.example"></a></span><a class="link" href="overload2.html#boost_asio.reference.basic_stream_socket.receive.overload2.example">Example</a>
</h6>
<p>
To receive into a single data buffer use the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
function as follows:
</p>
<pre class="programlisting">socket.receive(boost::asio::buffer(data, size), 0);
</pre>
<p>
See the <a class="link" href="../../buffer.html" title="buffer"><code class="computeroutput">buffer</code></a>
documentation for information on receiving into multiple buffers in one
go, and how to use it with arrays, boost::array or std::vector.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload1.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="overload3.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,99 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::receive (3 of 3 overloads)</title>
<link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../receive.html" title="basic_stream_socket::receive">
<link rel="prev" href="overload2.html" title="basic_stream_socket::receive (2 of 3 overloads)">
<link rel="next" href="../receive_buffer_size.html" title="basic_stream_socket::receive_buffer_size">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
<td align="center"><a href="../../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload2.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../receive_buffer_size.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h5 class="title">
<a name="boost_asio.reference.basic_stream_socket.receive.overload3"></a><a class="link" href="overload3.html" title="basic_stream_socket::receive (3 of 3 overloads)">basic_stream_socket::receive
(3 of 3 overloads)</a>
</h5></div></div></div>
<p>
Receive some data on a connected socket.
</p>
<pre class="programlisting">template&lt;
typename <a class="link" href="../../MutableBufferSequence.html" title="Mutable buffer sequence requirements">MutableBufferSequence</a>&gt;
std::size_t receive(
const MutableBufferSequence &amp; buffers,
socket_base::message_flags flags,
boost::system::error_code &amp; ec);
</pre>
<p>
This function is used to receive data on the stream socket. The function
call will block until one or more bytes of data has been received successfully,
or until an error occurs.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload3.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload3.parameters"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.receive.overload3.parameters">Parameters</a>
</h6>
<div class="variablelist">
<p class="title"><b></b></p>
<dl class="variablelist">
<dt><span class="term">buffers</span></dt>
<dd><p>
One or more buffers into which the data will be received.
</p></dd>
<dt><span class="term">flags</span></dt>
<dd><p>
Flags specifying how the receive call is to be made.
</p></dd>
<dt><span class="term">ec</span></dt>
<dd><p>
Set to indicate what error occurred, if any.
</p></dd>
</dl>
</div>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload3.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload3.return_value"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.receive.overload3.return_value">Return
Value</a>
</h6>
<p>
The number of bytes received. Returns 0 if an error occurred.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive.overload3.h2"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive.overload3.remarks"></a></span><a class="link" href="overload3.html#boost_asio.reference.basic_stream_socket.receive.overload3.remarks">Remarks</a>
</h6>
<p>
The receive operation may not receive all of the requested number of
bytes. Consider using the <a class="link" href="../../read.html" title="read"><code class="computeroutput">read</code></a>
function if you need to ensure that the requested amount of data is read
before the blocking operation completes.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="overload2.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../receive.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../boost_asio.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../receive_buffer_size.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,88 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>basic_stream_socket::receive_buffer_size</title>
<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../basic_stream_socket.html" title="basic_stream_socket">
<link rel="prev" href="receive/overload3.html" title="basic_stream_socket::receive (3 of 3 overloads)">
<link rel="next" href="receive_low_watermark.html" title="basic_stream_socket::receive_low_watermark">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
<td align="center"><a href="../../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="receive/overload3.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="receive_low_watermark.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="boost_asio.reference.basic_stream_socket.receive_buffer_size"></a><a class="link" href="receive_buffer_size.html" title="basic_stream_socket::receive_buffer_size">basic_stream_socket::receive_buffer_size</a>
</h4></div></div></div>
<p>
<span class="emphasis"><em>Inherited from socket_base.</em></span>
</p>
<p>
<a class="indexterm" name="boost_asio.indexterm.basic_stream_socket.receive_buffer_size"></a>
Socket
option for the receive buffer size of a socket.
</p>
<pre class="programlisting">typedef implementation_defined receive_buffer_size;
</pre>
<p>
Implements the SOL_SOCKET/SO_RCVBUF socket option.
</p>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive_buffer_size.h0"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive_buffer_size.examples"></a></span><a class="link" href="receive_buffer_size.html#boost_asio.reference.basic_stream_socket.receive_buffer_size.examples">Examples</a>
</h6>
<p>
Setting the option:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::receive_buffer_size option(8192);
socket.set_option(option);
</pre>
<p>
Getting the current option value:
</p>
<pre class="programlisting">boost::asio::ip::tcp::socket socket(my_context);
...
boost::asio::socket_base::receive_buffer_size option;
socket.get_option(option);
int size = option.value();
</pre>
<h6>
<a name="boost_asio.reference.basic_stream_socket.receive_buffer_size.h1"></a>
<span class="phrase"><a name="boost_asio.reference.basic_stream_socket.receive_buffer_size.requirements"></a></span><a class="link" href="receive_buffer_size.html#boost_asio.reference.basic_stream_socket.receive_buffer_size.requirements">Requirements</a>
</h6>
<p>
<span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/basic_stream_socket.hpp</code>
</p>
<p>
<span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2021 Christopher
M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="receive/overload3.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../basic_stream_socket.html"><img src="../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../boost_asio.html"><img src="../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="receive_low_watermark.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

Some files were not shown because too many files have changed in this diff Show More