1[/
2 / Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com)
3 /
4 / Distributed under the Boost Software License, Version 1.0. (See accompanying
5 / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6 /]
7
8[section:ConnectCondition Connect condition requirements]
9
10A type `X` meets the `ConnectCondition` requirements if it satisfies the
11requirements of `Destructible` (C++Std [destructible]) and
12`CopyConstructible` (C++Std [copyconstructible]), as well as the additional
13requirements listed below.
14
15In the table below, `x` denotes a value of type `X`, `ec` denotes a (possibly
16const) value of type `error_code`, and `ep` denotes a (possibly const) value of
17some type satisfying the [link boost_asio.reference.Endpoint endpoint] requirements.
18
19[table ConnectCondition requirements
20  [[expression] [return type] [assertion/note[br]pre/post-condition]]
21  [
22    [`x(ec, ep)`]
23    [`bool`]
24    [
25      Returns `true` to indicate that the `connect` or `async_connect`
26      algorithm should attempt a connection to the endpoint `ep`. Otherwise,
27      returns `false` to indicate that the algorithm should not attempt
28      connection to the endpoint `ep`, and should instead skip to the next
29      endpoint in the sequence.
30    ]
31  ]
32]
33
34[endsect]
35