• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<html>
2<head>
3<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
4<title>ip::tcp::endpoint</title>
5<link rel="stylesheet" href="../../../../../doc/src/boostbook.css" type="text/css">
6<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
7<link rel="home" href="../../../boost_asio.html" title="Boost.Asio">
8<link rel="up" href="../ip__tcp.html" title="ip::tcp">
9<link rel="prev" href="acceptor.html" title="ip::tcp::acceptor">
10<link rel="next" href="family.html" title="ip::tcp::family">
11</head>
12<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
13<table cellpadding="2" width="100%"><tr>
14<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../boost.png"></td>
15<td align="center"><a href="../../../../../index.html">Home</a></td>
16<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
17<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
18<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
19<td align="center"><a href="../../../../../more/index.htm">More</a></td>
20</tr></table>
21<hr>
22<div class="spirit-nav">
23<a accesskey="p" href="acceptor.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../ip__tcp.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="family.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
24</div>
25<div class="section">
26<div class="titlepage"><div><div><h4 class="title">
27<a name="boost_asio.reference.ip__tcp.endpoint"></a><a class="link" href="endpoint.html" title="ip::tcp::endpoint">ip::tcp::endpoint</a>
28</h4></div></div></div>
29<p>
30          <a class="indexterm" name="boost_asio.indexterm.ip__tcp.endpoint"></a>
31The type of a TCP endpoint.
32        </p>
33<pre class="programlisting">typedef basic_endpoint&lt; tcp &gt; endpoint;
34</pre>
35<h6>
36<a name="boost_asio.reference.ip__tcp.endpoint.h0"></a>
37          <span class="phrase"><a name="boost_asio.reference.ip__tcp.endpoint.types"></a></span><a class="link" href="endpoint.html#boost_asio.reference.ip__tcp.endpoint.types">Types</a>
38        </h6>
39<div class="informaltable"><table class="table">
40<colgroup>
41<col>
42<col>
43</colgroup>
44<thead><tr>
45<th>
46                  <p>
47                    Name
48                  </p>
49                </th>
50<th>
51                  <p>
52                    Description
53                  </p>
54                </th>
55</tr></thead>
56<tbody>
57<tr>
58<td>
59                  <p>
60                    <a class="link" href="../ip__basic_endpoint/data_type.html" title="ip::basic_endpoint::data_type"><span class="bold"><strong>data_type</strong></span></a>
61                  </p>
62                </td>
63<td>
64                  <p>
65                    The type of the endpoint structure. This type is dependent on
66                    the underlying implementation of the socket layer.
67                  </p>
68                </td>
69</tr>
70<tr>
71<td>
72                  <p>
73                    <a class="link" href="../ip__basic_endpoint/protocol_type.html" title="ip::basic_endpoint::protocol_type"><span class="bold"><strong>protocol_type</strong></span></a>
74                  </p>
75                </td>
76<td>
77                  <p>
78                    The protocol type associated with the endpoint.
79                  </p>
80                </td>
81</tr>
82</tbody>
83</table></div>
84<h6>
85<a name="boost_asio.reference.ip__tcp.endpoint.h1"></a>
86          <span class="phrase"><a name="boost_asio.reference.ip__tcp.endpoint.member_functions"></a></span><a class="link" href="endpoint.html#boost_asio.reference.ip__tcp.endpoint.member_functions">Member
87          Functions</a>
88        </h6>
89<div class="informaltable"><table class="table">
90<colgroup>
91<col>
92<col>
93</colgroup>
94<thead><tr>
95<th>
96                  <p>
97                    Name
98                  </p>
99                </th>
100<th>
101                  <p>
102                    Description
103                  </p>
104                </th>
105</tr></thead>
106<tbody>
107<tr>
108<td>
109                  <p>
110                    <a class="link" href="../ip__basic_endpoint/address.html" title="ip::basic_endpoint::address"><span class="bold"><strong>address</strong></span></a>
111                  </p>
112                </td>
113<td>
114                  <p>
115                    Get the IP address associated with the endpoint. <br> <span class="silver"> —</span><br>
116                    Set the IP address associated with the endpoint.
117                  </p>
118                </td>
119</tr>
120<tr>
121<td>
122                  <p>
123                    <a class="link" href="../ip__basic_endpoint/basic_endpoint.html" title="ip::basic_endpoint::basic_endpoint"><span class="bold"><strong>basic_endpoint</strong></span></a> <span class="silver">[constructor]</span>
124                  </p>
125                </td>
126<td>
127                  <p>
128                    Default constructor. <br> <span class="silver"> —</span><br> Construct an endpoint using
129                    a port number, specified in the host's byte order. The IP address
130                    will be the any address (i.e. INADDR_ANY or in6addr_any). This
131                    constructor would typically be used for accepting new connections.
132                    <br> <span class="silver"> —</span><br> Construct an endpoint using a port number and an
133                    IP address. This constructor may be used for accepting connections
134                    on a specific interface or for making a connection to a remote
135                    endpoint. <br> <span class="silver"> —</span><br> Copy constructor. <br> <span class="silver"> —</span><br> Move
136                    constructor.
137                  </p>
138                </td>
139</tr>
140<tr>
141<td>
142                  <p>
143                    <a class="link" href="../ip__basic_endpoint/capacity.html" title="ip::basic_endpoint::capacity"><span class="bold"><strong>capacity</strong></span></a>
144                  </p>
145                </td>
146<td>
147                  <p>
148                    Get the capacity of the endpoint in the native type.
149                  </p>
150                </td>
151</tr>
152<tr>
153<td>
154                  <p>
155                    <a class="link" href="../ip__basic_endpoint/data.html" title="ip::basic_endpoint::data"><span class="bold"><strong>data</strong></span></a>
156                  </p>
157                </td>
158<td>
159                  <p>
160                    Get the underlying endpoint in the native type.
161                  </p>
162                </td>
163</tr>
164<tr>
165<td>
166                  <p>
167                    <a class="link" href="../ip__basic_endpoint/operator_eq_.html" title="ip::basic_endpoint::operator="><span class="bold"><strong>operator=</strong></span></a>
168                  </p>
169                </td>
170<td>
171                  <p>
172                    Assign from another endpoint. <br> <span class="silver"> —</span><br> Move-assign from
173                    another endpoint.
174                  </p>
175                </td>
176</tr>
177<tr>
178<td>
179                  <p>
180                    <a class="link" href="../ip__basic_endpoint/port.html" title="ip::basic_endpoint::port"><span class="bold"><strong>port</strong></span></a>
181                  </p>
182                </td>
183<td>
184                  <p>
185                    Get the port associated with the endpoint. The port number is
186                    always in the host's byte order. <br> <span class="silver"> —</span><br> Set the port associated
187                    with the endpoint. The port number is always in the host's byte
188                    order.
189                  </p>
190                </td>
191</tr>
192<tr>
193<td>
194                  <p>
195                    <a class="link" href="../ip__basic_endpoint/protocol.html" title="ip::basic_endpoint::protocol"><span class="bold"><strong>protocol</strong></span></a>
196                  </p>
197                </td>
198<td>
199                  <p>
200                    The protocol associated with the endpoint.
201                  </p>
202                </td>
203</tr>
204<tr>
205<td>
206                  <p>
207                    <a class="link" href="../ip__basic_endpoint/resize.html" title="ip::basic_endpoint::resize"><span class="bold"><strong>resize</strong></span></a>
208                  </p>
209                </td>
210<td>
211                  <p>
212                    Set the underlying size of the endpoint in the native type.
213                  </p>
214                </td>
215</tr>
216<tr>
217<td>
218                  <p>
219                    <a class="link" href="../ip__basic_endpoint/size.html" title="ip::basic_endpoint::size"><span class="bold"><strong>size</strong></span></a>
220                  </p>
221                </td>
222<td>
223                  <p>
224                    Get the underlying size of the endpoint in the native type.
225                  </p>
226                </td>
227</tr>
228</tbody>
229</table></div>
230<h6>
231<a name="boost_asio.reference.ip__tcp.endpoint.h2"></a>
232          <span class="phrase"><a name="boost_asio.reference.ip__tcp.endpoint.friends"></a></span><a class="link" href="endpoint.html#boost_asio.reference.ip__tcp.endpoint.friends">Friends</a>
233        </h6>
234<div class="informaltable"><table class="table">
235<colgroup>
236<col>
237<col>
238</colgroup>
239<thead><tr>
240<th>
241                  <p>
242                    Name
243                  </p>
244                </th>
245<th>
246                  <p>
247                    Description
248                  </p>
249                </th>
250</tr></thead>
251<tbody>
252<tr>
253<td>
254                  <p>
255                    <a class="link" href="../ip__basic_endpoint/operator_not__eq_.html" title="ip::basic_endpoint::operator!="><span class="bold"><strong>operator!=</strong></span></a>
256                  </p>
257                </td>
258<td>
259                  <p>
260                    Compare two endpoints for inequality.
261                  </p>
262                </td>
263</tr>
264<tr>
265<td>
266                  <p>
267                    <a class="link" href="../ip__basic_endpoint/operator_lt_.html" title="ip::basic_endpoint::operator&lt;"><span class="bold"><strong>operator&lt;</strong></span></a>
268                  </p>
269                </td>
270<td>
271                  <p>
272                    Compare endpoints for ordering.
273                  </p>
274                </td>
275</tr>
276<tr>
277<td>
278                  <p>
279                    <a class="link" href="../ip__basic_endpoint/operator_lt__eq_.html" title="ip::basic_endpoint::operator&lt;="><span class="bold"><strong>operator&lt;=</strong></span></a>
280                  </p>
281                </td>
282<td>
283                  <p>
284                    Compare endpoints for ordering.
285                  </p>
286                </td>
287</tr>
288<tr>
289<td>
290                  <p>
291                    <a class="link" href="../ip__basic_endpoint/operator_eq__eq_.html" title="ip::basic_endpoint::operator=="><span class="bold"><strong>operator==</strong></span></a>
292                  </p>
293                </td>
294<td>
295                  <p>
296                    Compare two endpoints for equality.
297                  </p>
298                </td>
299</tr>
300<tr>
301<td>
302                  <p>
303                    <a class="link" href="../ip__basic_endpoint/operator_gt_.html" title="ip::basic_endpoint::operator&gt;"><span class="bold"><strong>operator&gt;</strong></span></a>
304                  </p>
305                </td>
306<td>
307                  <p>
308                    Compare endpoints for ordering.
309                  </p>
310                </td>
311</tr>
312<tr>
313<td>
314                  <p>
315                    <a class="link" href="../ip__basic_endpoint/operator_gt__eq_.html" title="ip::basic_endpoint::operator&gt;="><span class="bold"><strong>operator&gt;=</strong></span></a>
316                  </p>
317                </td>
318<td>
319                  <p>
320                    Compare endpoints for ordering.
321                  </p>
322                </td>
323</tr>
324</tbody>
325</table></div>
326<h6>
327<a name="boost_asio.reference.ip__tcp.endpoint.h3"></a>
328          <span class="phrase"><a name="boost_asio.reference.ip__tcp.endpoint.related_functions"></a></span><a class="link" href="endpoint.html#boost_asio.reference.ip__tcp.endpoint.related_functions">Related
329          Functions</a>
330        </h6>
331<div class="informaltable"><table class="table">
332<colgroup>
333<col>
334<col>
335</colgroup>
336<thead><tr>
337<th>
338                  <p>
339                    Name
340                  </p>
341                </th>
342<th>
343                  <p>
344                    Description
345                  </p>
346                </th>
347</tr></thead>
348<tbody><tr>
349<td>
350                  <p>
351                    <a class="link" href="../ip__basic_endpoint/operator_lt__lt_.html" title="ip::basic_endpoint::operator&lt;&lt;"><span class="bold"><strong>operator&lt;&lt;</strong></span></a>
352                  </p>
353                </td>
354<td>
355                  <p>
356                    Output an endpoint as a string.
357                  </p>
358                </td>
359</tr></tbody>
360</table></div>
361<p>
362          The <a class="link" href="../ip__basic_endpoint.html" title="ip::basic_endpoint"><code class="computeroutput">ip::basic_endpoint</code></a>
363          class template describes an endpoint that may be associated with a particular
364          socket.
365        </p>
366<h6>
367<a name="boost_asio.reference.ip__tcp.endpoint.h4"></a>
368          <span class="phrase"><a name="boost_asio.reference.ip__tcp.endpoint.thread_safety"></a></span><a class="link" href="endpoint.html#boost_asio.reference.ip__tcp.endpoint.thread_safety">Thread Safety</a>
369        </h6>
370<p>
371          <span class="emphasis"><em>Distinct</em></span> <span class="emphasis"><em>objects:</em></span> Safe.
372        </p>
373<p>
374          <span class="emphasis"><em>Shared</em></span> <span class="emphasis"><em>objects:</em></span> Unsafe.
375        </p>
376<h6>
377<a name="boost_asio.reference.ip__tcp.endpoint.h5"></a>
378          <span class="phrase"><a name="boost_asio.reference.ip__tcp.endpoint.requirements"></a></span><a class="link" href="endpoint.html#boost_asio.reference.ip__tcp.endpoint.requirements">Requirements</a>
379        </h6>
380<p>
381          <span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/ip/tcp.hpp</code>
382        </p>
383<p>
384          <span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
385        </p>
386</div>
387<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
388<td align="left"></td>
389<td align="right"><div class="copyright-footer">Copyright © 2003-2020 Christopher M.
390      Kohlhoff<p>
391        Distributed under the Boost Software License, Version 1.0. (See accompanying
392        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>)
393      </p>
394</div></td>
395</tr></table>
396<hr>
397<div class="spirit-nav">
398<a accesskey="p" href="acceptor.html"><img src="../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../ip__tcp.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="family.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
399</div>
400</body>
401</html>
402