Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf9ff4cd

Browse files
committed
Tag Table for HTTP Client Tags
This commit moves out the Table of Tags supported by the HTTP Client``basic_client`` template. This table is shown in two locations, one inthe in-depth part of the HTTP implementation documentation, and anotherat the HTTP Client API reference manual.This commit also fleshes out the implementation section of the HTTPClient API reference manual.
1 parenta7e1558 commitf9ff4cd

File tree

3 files changed

+65
-41
lines changed

3 files changed

+65
-41
lines changed

‎libs/network/doc/http.rst‎

Lines changed: 2 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -25,46 +25,9 @@ determine the behavior of the ``basic_client``. The interface of
2525
you provide. Below is a table of predefined supported tags you can use in your
2626
overload of the ``basic_client``:
2727

28+
------------
2829

29-
+---------------------------------+---------------------------------------------+
30-
| Tag| Description|
31-
+=================================+=============================================+
32-
| http_default_8bit_tcp_resolve| This is the default HTTP implementation tag|
33-
|| that resolves addresses with a TCP resolver|
34-
|| and provides a synchronous/blocking HTTP|
35-
|| client interface.|
36-
+---------------------------------+---------------------------------------------+
37-
| http_default_8bit_udp_resolve| This is similar to the above tag except that|
38-
|| it specifies the HTTP client to use a UDP|
39-
|| resolver. It also provides a synchronous/|
40-
|| blocking HTTP client interface.|
41-
+---------------------------------+---------------------------------------------+
42-
| http_keepalive_8bit_tcp_resolve| This tag specifies that the HTTP client by|
43-
|| default will keep connections to the server|
44-
|| alive. It only makes sense if the|
45-
|| ``version_major`` and ``version_minor`` are|
46-
|| both ``1``, to indicate HTTP 1.1. This tag|
47-
|| causes the HTTP client to resolve using a|
48-
|| TCP resolver and provides a synchronous/|
49-
|| blocking HTTP client interface.|
50-
+---------------------------------+---------------------------------------------+
51-
| http_keepalive_8bit_udp_resolve| This is similar to the above tag except that|
52-
|| it specifies the HTTP client to use a UDP|
53-
|| resolver. It also provides a synchronous/|
54-
|| blocking HTTP client interface.|
55-
+---------------------------------+---------------------------------------------+
56-
| http_async_8bit_tcp_resolve| This tag provides an active HTTP client|
57-
|| object implementation that uses a TCP|
58-
|| resolver. Response objects returned will|
59-
|| encapsulate a number ofBoost.Thread_|
60-
|| shared futures to hold values. Users don't|
61-
|| have to see this as they are implementation|
62-
|| details.|
63-
+---------------------------------+---------------------------------------------+
64-
| http_async_8bit_udp_resolve| This is similar to the above tag except that|
65-
|| specifies the HTTP client to use a UDP|
66-
|| resolver.|
67-
+---------------------------------+---------------------------------------------+
30+
..include::http_client_tags.rst
6831

6932
.. _Boost.Thread:http://www.boost.org/libs/thread
7033

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
2+
+---------------------------------+---------------------------------------------+
3+
| Tag| Description|
4+
+=================================+=============================================+
5+
| http_default_8bit_tcp_resolve| This is the default HTTP implementation tag|
6+
|| that resolves addresses with a TCP resolver|
7+
|| and provides a synchronous/blocking HTTP|
8+
|| client interface.|
9+
+---------------------------------+---------------------------------------------+
10+
| http_default_8bit_udp_resolve| This is similar to the above tag except that|
11+
|| it specifies the HTTP client to use a UDP|
12+
|| resolver. It also provides a synchronous/|
13+
|| blocking HTTP client interface.|
14+
+---------------------------------+---------------------------------------------+
15+
| http_keepalive_8bit_tcp_resolve| This tag specifies that the HTTP client by|
16+
|| default will keep connections to the server|
17+
|| alive. It only makes sense if the|
18+
|| ``version_major`` and ``version_minor`` are|
19+
|| both ``1``, to indicate HTTP 1.1. This tag|
20+
|| causes the HTTP client to resolve using a|
21+
|| TCP resolver and provides a synchronous/|
22+
|| blocking HTTP client interface.|
23+
+---------------------------------+---------------------------------------------+
24+
| http_keepalive_8bit_udp_resolve| This is similar to the above tag except that|
25+
|| it specifies the HTTP client to use a UDP|
26+
|| resolver. It also provides a synchronous/|
27+
|| blocking HTTP client interface.|
28+
+---------------------------------+---------------------------------------------+
29+
| http_async_8bit_tcp_resolve| This tag provides an active HTTP client|
30+
|| object implementation that uses a TCP|
31+
|| resolver. Response objects returned will|
32+
|| encapsulate a number ofBoost.Thread_|
33+
|| shared futures to hold values. Users don't|
34+
|| have to see this as they are implementation|
35+
|| details.|
36+
+---------------------------------+---------------------------------------------+
37+
| http_async_8bit_udp_resolve| This is similar to the above tag except that|
38+
|| specifies the HTTP client to use a UDP|
39+
|| resolver.|
40+
+---------------------------------+---------------------------------------------+
41+
42+
.. _Boost.Thread:http://www.boost.org/libs/thread
43+

‎libs/network/doc/reference_http_client.rst‎

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,26 @@ implementations.
2525
Implementations
2626
---------------
2727

28-
.. FIXME describe the internal implementation, with diagrams if at all possible
29-
and within reasonable efforts.
28+
There is a single user-facing template class named ``basic_client`` which takes
29+
three template parameters:
30+
31+
* **Tag** - which static tag you choose that defines the behavior of the client.
32+
33+
* **http_version_major** - an unsigned int that defines the HTTP major version
34+
number, this directly affects the HTTP messages sent by the client.
35+
36+
* **http_version_minor** - an unsigned int that defines the HTTP minor version
37+
number.
38+
39+
There are two major different class of implementations of the ``basic_client``
40+
template that depend on which tag you choose: `Synchronous Clients`_ and
41+
`Asynchronous Clients`_. These two different classes are described in their own
42+
sections following this one. What follows is a table of all tags supported by
43+
the HTTP client implementation provided by:mod:`cpp-netlib`.
44+
45+
---------------
46+
47+
..include::http_client_tags.rst
3048

3149
Synchronous Clients
3250
~~~~~~~~~~~~~~~~~~~

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp