• 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::resolver</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="protocol.html" title="ip::tcp::protocol">
10<link rel="next" href="socket.html" title="ip::tcp::socket">
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="protocol.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="socket.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.resolver"></a><a class="link" href="resolver.html" title="ip::tcp::resolver">ip::tcp::resolver</a>
28</h4></div></div></div>
29<p>
30          <a class="indexterm" name="boost_asio.indexterm.ip__tcp.resolver"></a>
31The TCP resolver type.
32        </p>
33<pre class="programlisting">typedef basic_resolver&lt; tcp &gt; resolver;
34</pre>
35<h6>
36<a name="boost_asio.reference.ip__tcp.resolver.h0"></a>
37          <span class="phrase"><a name="boost_asio.reference.ip__tcp.resolver.types"></a></span><a class="link" href="resolver.html#boost_asio.reference.ip__tcp.resolver.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_resolver__rebind_executor.html" title="ip::basic_resolver::rebind_executor"><span class="bold"><strong>rebind_executor</strong></span></a>
61                  </p>
62                </td>
63<td>
64                  <p>
65                    Rebinds the resolver type to another executor.
66                  </p>
67                </td>
68</tr>
69<tr>
70<td>
71                  <p>
72                    <a class="link" href="../ip__basic_resolver/endpoint_type.html" title="ip::basic_resolver::endpoint_type"><span class="bold"><strong>endpoint_type</strong></span></a>
73                  </p>
74                </td>
75<td>
76                  <p>
77                    The endpoint type.
78                  </p>
79                </td>
80</tr>
81<tr>
82<td>
83                  <p>
84                    <a class="link" href="../ip__basic_resolver/executor_type.html" title="ip::basic_resolver::executor_type"><span class="bold"><strong>executor_type</strong></span></a>
85                  </p>
86                </td>
87<td>
88                  <p>
89                    The type of the executor associated with the object.
90                  </p>
91                </td>
92</tr>
93<tr>
94<td>
95                  <p>
96                    <a class="link" href="../ip__basic_resolver/flags.html" title="ip::basic_resolver::flags"><span class="bold"><strong>flags</strong></span></a>
97                  </p>
98                </td>
99<td>
100                  <p>
101                    A bitmask type (C++ Std [lib.bitmask.types]).
102                  </p>
103                </td>
104</tr>
105<tr>
106<td>
107                  <p>
108                    <a class="link" href="../ip__basic_resolver/iterator.html" title="ip::basic_resolver::iterator"><span class="bold"><strong>iterator</strong></span></a>
109                  </p>
110                </td>
111<td>
112                  <p>
113                    (Deprecated.) The iterator type.
114                  </p>
115                </td>
116</tr>
117<tr>
118<td>
119                  <p>
120                    <a class="link" href="../ip__basic_resolver/protocol_type.html" title="ip::basic_resolver::protocol_type"><span class="bold"><strong>protocol_type</strong></span></a>
121                  </p>
122                </td>
123<td>
124                  <p>
125                    The protocol type.
126                  </p>
127                </td>
128</tr>
129<tr>
130<td>
131                  <p>
132                    <a class="link" href="../ip__basic_resolver/query.html" title="ip::basic_resolver::query"><span class="bold"><strong>query</strong></span></a>
133                  </p>
134                </td>
135<td>
136                  <p>
137                    (Deprecated.) The query type.
138                  </p>
139                </td>
140</tr>
141<tr>
142<td>
143                  <p>
144                    <a class="link" href="../ip__basic_resolver/results_type.html" title="ip::basic_resolver::results_type"><span class="bold"><strong>results_type</strong></span></a>
145                  </p>
146                </td>
147<td>
148                  <p>
149                    The results type.
150                  </p>
151                </td>
152</tr>
153</tbody>
154</table></div>
155<h6>
156<a name="boost_asio.reference.ip__tcp.resolver.h1"></a>
157          <span class="phrase"><a name="boost_asio.reference.ip__tcp.resolver.member_functions"></a></span><a class="link" href="resolver.html#boost_asio.reference.ip__tcp.resolver.member_functions">Member
158          Functions</a>
159        </h6>
160<div class="informaltable"><table class="table">
161<colgroup>
162<col>
163<col>
164</colgroup>
165<thead><tr>
166<th>
167                  <p>
168                    Name
169                  </p>
170                </th>
171<th>
172                  <p>
173                    Description
174                  </p>
175                </th>
176</tr></thead>
177<tbody>
178<tr>
179<td>
180                  <p>
181                    <a class="link" href="../ip__basic_resolver/async_resolve.html" title="ip::basic_resolver::async_resolve"><span class="bold"><strong>async_resolve</strong></span></a>
182                  </p>
183                </td>
184<td>
185                  <p>
186                    (Deprecated: Use overload with separate host and service parameters.)
187                    Asynchronously perform forward resolution of a query to a list
188                    of entries. <br> <span class="silver"> —</span><br> Asynchronously perform forward resolution
189                    of a query to a list of entries. <br> <span class="silver"> —</span><br> Asynchronously
190                    perform reverse resolution of an endpoint to a list of entries.
191                  </p>
192                </td>
193</tr>
194<tr>
195<td>
196                  <p>
197                    <a class="link" href="../ip__basic_resolver/basic_resolver.html" title="ip::basic_resolver::basic_resolver"><span class="bold"><strong>basic_resolver</strong></span></a> <span class="silver">[constructor]</span>
198                  </p>
199                </td>
200<td>
201                  <p>
202                    Construct with executor. <br> <span class="silver"> —</span><br> Construct with execution
203                    context. <br> <span class="silver"> —</span><br> Move-construct a basic_resolver from another.
204                  </p>
205                </td>
206</tr>
207<tr>
208<td>
209                  <p>
210                    <a class="link" href="../ip__basic_resolver/cancel.html" title="ip::basic_resolver::cancel"><span class="bold"><strong>cancel</strong></span></a>
211                  </p>
212                </td>
213<td>
214                  <p>
215                    Cancel any asynchronous operations that are waiting on the resolver.
216                  </p>
217                </td>
218</tr>
219<tr>
220<td>
221                  <p>
222                    <a class="link" href="../ip__basic_resolver/get_executor.html" title="ip::basic_resolver::get_executor"><span class="bold"><strong>get_executor</strong></span></a>
223                  </p>
224                </td>
225<td>
226                  <p>
227                    Get the executor associated with the object.
228                  </p>
229                </td>
230</tr>
231<tr>
232<td>
233                  <p>
234                    <a class="link" href="../ip__basic_resolver/operator_eq_.html" title="ip::basic_resolver::operator="><span class="bold"><strong>operator=</strong></span></a>
235                  </p>
236                </td>
237<td>
238                  <p>
239                    Move-assign a basic_resolver from another.
240                  </p>
241                </td>
242</tr>
243<tr>
244<td>
245                  <p>
246                    <a class="link" href="../ip__basic_resolver/resolve.html" title="ip::basic_resolver::resolve"><span class="bold"><strong>resolve</strong></span></a>
247                  </p>
248                </td>
249<td>
250                  <p>
251                    (Deprecated: Use overload with separate host and service parameters.)
252                    Perform forward resolution of a query to a list of entries.
253                    <br> <span class="silver"> —</span><br> Perform forward resolution of a query to a list
254                    of entries. <br> <span class="silver"> —</span><br> Perform reverse resolution of an endpoint
255                    to a list of entries.
256                  </p>
257                </td>
258</tr>
259<tr>
260<td>
261                  <p>
262                    <a class="link" href="../ip__basic_resolver/_basic_resolver.html" title="ip::basic_resolver::~basic_resolver"><span class="bold"><strong>~basic_resolver</strong></span></a> <span class="silver">[destructor]</span>
263                  </p>
264                </td>
265<td>
266                  <p>
267                    Destroys the resolver.
268                  </p>
269                </td>
270</tr>
271</tbody>
272</table></div>
273<h6>
274<a name="boost_asio.reference.ip__tcp.resolver.h2"></a>
275          <span class="phrase"><a name="boost_asio.reference.ip__tcp.resolver.data_members"></a></span><a class="link" href="resolver.html#boost_asio.reference.ip__tcp.resolver.data_members">Data Members</a>
276        </h6>
277<div class="informaltable"><table class="table">
278<colgroup>
279<col>
280<col>
281</colgroup>
282<thead><tr>
283<th>
284                  <p>
285                    Name
286                  </p>
287                </th>
288<th>
289                  <p>
290                    Description
291                  </p>
292                </th>
293</tr></thead>
294<tbody>
295<tr>
296<td>
297                  <p>
298                    <a class="link" href="../ip__basic_resolver/address_configured.html" title="ip::basic_resolver::address_configured"><span class="bold"><strong>address_configured</strong></span></a> <span class="silver">[static]</span>
299                  </p>
300                </td>
301<td>
302                  <p>
303                    Only return IPv4 addresses if a non-loopback IPv4 address is
304                    configured for the system. Only return IPv6 addresses if a non-loopback
305                    IPv6 address is configured for the system.
306                  </p>
307                </td>
308</tr>
309<tr>
310<td>
311                  <p>
312                    <a class="link" href="../ip__basic_resolver/all_matching.html" title="ip::basic_resolver::all_matching"><span class="bold"><strong>all_matching</strong></span></a> <span class="silver">[static]</span>
313                  </p>
314                </td>
315<td>
316                  <p>
317                    If used with v4_mapped, return all matching IPv6 and IPv4 addresses.
318                  </p>
319                </td>
320</tr>
321<tr>
322<td>
323                  <p>
324                    <a class="link" href="../ip__basic_resolver/canonical_name.html" title="ip::basic_resolver::canonical_name"><span class="bold"><strong>canonical_name</strong></span></a> <span class="silver">[static]</span>
325                  </p>
326                </td>
327<td>
328                  <p>
329                    Determine the canonical name of the host specified in the query.
330                  </p>
331                </td>
332</tr>
333<tr>
334<td>
335                  <p>
336                    <a class="link" href="../ip__basic_resolver/numeric_host.html" title="ip::basic_resolver::numeric_host"><span class="bold"><strong>numeric_host</strong></span></a> <span class="silver">[static]</span>
337                  </p>
338                </td>
339<td>
340                  <p>
341                    Host name should be treated as a numeric string defining an IPv4
342                    or IPv6 address and no name resolution should be attempted.
343                  </p>
344                </td>
345</tr>
346<tr>
347<td>
348                  <p>
349                    <a class="link" href="../ip__basic_resolver/numeric_service.html" title="ip::basic_resolver::numeric_service"><span class="bold"><strong>numeric_service</strong></span></a> <span class="silver">[static]</span>
350                  </p>
351                </td>
352<td>
353                  <p>
354                    Service name should be treated as a numeric string defining a
355                    port number and no name resolution should be attempted.
356                  </p>
357                </td>
358</tr>
359<tr>
360<td>
361                  <p>
362                    <a class="link" href="../ip__basic_resolver/passive.html" title="ip::basic_resolver::passive"><span class="bold"><strong>passive</strong></span></a> <span class="silver">[static]</span>
363                  </p>
364                </td>
365<td>
366                  <p>
367                    Indicate that returned endpoint is intended for use as a locally
368                    bound socket endpoint.
369                  </p>
370                </td>
371</tr>
372<tr>
373<td>
374                  <p>
375                    <a class="link" href="../ip__basic_resolver/v4_mapped.html" title="ip::basic_resolver::v4_mapped"><span class="bold"><strong>v4_mapped</strong></span></a> <span class="silver">[static]</span>
376                  </p>
377                </td>
378<td>
379                  <p>
380                    If the query protocol family is specified as IPv6, return IPv4-mapped
381                    IPv6 addresses on finding no IPv6 addresses.
382                  </p>
383                </td>
384</tr>
385</tbody>
386</table></div>
387<p>
388          The <a class="link" href="../ip__basic_resolver.html" title="ip::basic_resolver"><code class="computeroutput">ip::basic_resolver</code></a>
389          class template provides the ability to resolve a query to a list of endpoints.
390        </p>
391<h6>
392<a name="boost_asio.reference.ip__tcp.resolver.h3"></a>
393          <span class="phrase"><a name="boost_asio.reference.ip__tcp.resolver.thread_safety"></a></span><a class="link" href="resolver.html#boost_asio.reference.ip__tcp.resolver.thread_safety">Thread Safety</a>
394        </h6>
395<p>
396          <span class="emphasis"><em>Distinct</em></span> <span class="emphasis"><em>objects:</em></span> Safe.
397        </p>
398<p>
399          <span class="emphasis"><em>Shared</em></span> <span class="emphasis"><em>objects:</em></span> Unsafe.
400        </p>
401<h6>
402<a name="boost_asio.reference.ip__tcp.resolver.h4"></a>
403          <span class="phrase"><a name="boost_asio.reference.ip__tcp.resolver.requirements"></a></span><a class="link" href="resolver.html#boost_asio.reference.ip__tcp.resolver.requirements">Requirements</a>
404        </h6>
405<p>
406          <span class="emphasis"><em>Header: </em></span><code class="literal">boost/asio/ip/tcp.hpp</code>
407        </p>
408<p>
409          <span class="emphasis"><em>Convenience header: </em></span><code class="literal">boost/asio.hpp</code>
410        </p>
411</div>
412<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
413<td align="left"></td>
414<td align="right"><div class="copyright-footer">Copyright © 2003-2020 Christopher M.
415      Kohlhoff<p>
416        Distributed under the Boost Software License, Version 1.0. (See accompanying
417        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>)
418      </p>
419</div></td>
420</tr></table>
421<hr>
422<div class="spirit-nav">
423<a accesskey="p" href="protocol.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="socket.html"><img src="../../../../../doc/src/images/next.png" alt="Next"></a>
424</div>
425</body>
426</html>
427