Disable sends or receives on the socket. * This function is used to disable send operations, receive operations, or * both. * * @param what Determines what types of operation will no longer be allowed. * * @throws asio::system_error Thrown on failure. * * @par Example * Shutting down the send side of the socket: * @code * asio::ip::tcp::socket socket(my_context); *
| 1669 | * @endcode |
| 1670 | */ |
| 1671 | void shutdown(shutdown_type what) |
| 1672 | { |
| 1673 | asio::error_code ec; |
| 1674 | impl_.get_service().shutdown(impl_.get_implementation(), what, ec); |
| 1675 | asio::detail::throw_error(ec, "shutdown"); |
| 1676 | } |
| 1677 | |
| 1678 | /// Disable sends or receives on the socket. |
| 1679 | /** |