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

Commita90bfd5

Browse files
committed
Updated URI documentation and examples.
1 parente962f2e commita90bfd5

File tree

20 files changed

+856
-64
lines changed

20 files changed

+856
-64
lines changed

‎boost/network/protocol/http/impl/request.hpp‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,7 @@ namespace boost { namespace network { namespace http {
4343
public:
4444
typedeftypename sync_only<Tag>::type tag;
4545
typedeftypename string<tag>::type string_type;
46-
// typedef boost::uint16_t port_type;
47-
typedef string_type port_type;
46+
typedef boost::uint16_t port_type;
4847

4948
explicitbasic_request(string_typeconst & uri_)
5049
: uri_(uri_)

‎boost/network/uri/basic_uri.hpp‎

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,6 @@ struct uri_base {
6262
}
6363

6464
uint16_tport()const {
65-
// string_type port() const {
6665
return parts_.port ? *parts_.port :0;
6766
}
6867

@@ -87,6 +86,10 @@ struct uri_base {
8786
}
8887

8988
boolvalid()const {
89+
returnis_valid();
90+
}
91+
92+
boolis_valid()const {
9093
return valid_;
9194
}
9295

@@ -110,10 +113,6 @@ class basic_uri : public uri_base<Tag> {
110113

111114
public:
112115

113-
// using uri_base<Tag>::operator=;
114-
// using typename uri_base<Tag>::string_type;
115-
// using uri_base<Tag>::operator==;
116-
// using uri_base<Tag>::operator!=;
117116
basic_uri() : uri_base<Tag>() {}
118117
basic_uri(typename uri_base<Tag>::string_typeconst & uri) : uri_base<Tag>(uri) {}
119118

@@ -149,7 +148,6 @@ host(basic_uri<Tag> const & uri) {
149148
template<classTag>
150149
inline
151150
uint16_t
152-
// typename string<Tag>::type
153151
port(basic_uri<Tag>const & uri) {
154152
return uri.port();
155153
}
@@ -181,6 +179,13 @@ bool
181179
valid(basic_uri<Tag>const & uri) {
182180
return uri.valid();
183181
}
182+
183+
template<classTag>
184+
inline
185+
bool
186+
is_valid(basic_uri<Tag>const & uri) {
187+
return uri.is_valid();
188+
}
184189
}// namespace uri
185190
}// namespace network
186191
}// namespace boost

‎boost/network/uri/detail/parse_uri.hpp‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ template <class Tag>
2424
structtransform_attribute<
2525
boost::network::uri::detail::uri_parts<Tag>,
2626
typename boost::network::uri::detail::uri_parts_tuple<Tag>::type
27-
#if SPIRIT_VERSION > 0x2030
27+
#if SPIRIT_VERSION >= 0x2030
2828
, boost::spirit::qi::domain
2929
#endif
3030
>
@@ -37,7 +37,6 @@ struct transform_attribute<
3737
boost::fusion::tuple<
3838
boost::optional<string_type> &,
3939
boost::optional<string_type> &,
40-
// boost::optional<string_type> &,
4140
boost::optional<boost::uint16_t> &,
4241
string_type &
4342
> hier_part =

‎boost/network/uri/detail/uri_parts.hpp‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ struct uri_parts {
2323
string_type scheme;
2424
optional<string_type> user_info;
2525
optional<string_type> host;
26-
// optional<string_type> port;
2726
optional<boost::uint16_t> port;
2827
string_type path;
2928
optional<string_type> query;
@@ -39,7 +38,6 @@ struct uri_parts_tuple {
3938
boost::fusion::tuple<
4039
optional<string_type> &,
4140
optional<string_type> &,
42-
// optional<string_type> &,
4341
optional<boost::uint16_t> &,
4442
string_type &
4543
>,

‎boost/network/uri/http/uri.hpp‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,18 @@
88

99
#include<boost/cstdint.hpp>
1010
#include<boost/algorithm/string/predicate.hpp>
11-
1211
#include<boost/network/protocol/http/tags.hpp>
1312
#include<boost/network/traits/string.hpp>
1413
#include<boost/network/uri/basic_uri.hpp>
1514
#include<boost/network/uri/http/detail/parse_specific.hpp>
1615

16+
1717
namespaceboost {namespacenetwork {namespaceuri {
1818
template<>
1919
classbasic_uri<http::tags::http_default_8bit_tcp_resolve>
2020
: public uri_base<http::tags::http_default_8bit_tcp_resolve> {
2121

2222
public:
23-
// typedef uri_base<http::tags::http_default_8bit_tcp_resolve>::string_type string_type;
24-
// using uri_base<http::tags::http_default_8bit_tcp_resolve>::operator=;
25-
// using uri_base<http::tags::http_default_8bit_tcp_resolve>::swap;
26-
2723
basic_uri() : uri_base<http::tags::http_default_8bit_tcp_resolve>() {}
2824
basic_uri(uri_base<http::tags::http_default_8bit_tcp_resolve>::string_typeconst & uri) : uri_base<http::tags::http_default_8bit_tcp_resolve>(uri) {}
2925

‎boost/network/uri/uri.hpp‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
// Copyright (c) Glyn Matthews 2010.
2+
// Distributed under the Boost Software License, Version 1.0.
3+
// (See accompanying file LICENSE_1_0.txt or copy at
4+
// http://www.boost.org/LICENSE_1_0.txt)
5+
6+
7+
#ifndef __BOOST_NETWORK_URI_URI_INC__
8+
#define__BOOST_NETWORK_URI_URI_INC__
9+
10+
11+
#include<boost/network/uri/basic_uri.hpp>
12+
13+
14+
#endif// __BOOST_NETWORK_URI_URI_INC__

‎boost/network/uri/uri_concept.hpp‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,11 @@ namespace boost { namespace network { namespace uri {
2626
string_type host_ =host(uri);
2727
uint16_t port_ =port(uri);
2828
port_ =0;
29-
// string_type port_ = port(uri);
3029
string_type path_ =path(uri);
3130
string_type query_ =query(uri);
3231
string_type fragment_ =fragment(uri);
3332

34-
bool valid_ =valid(uri);
33+
bool valid_ =is_valid(uri);
3534
valid_ =false;
3635
}
3736

‎libs/network/benchmarks/README.rst‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Here we can collect some statistics about different areas of
2+
performance in the:mod:`cpp-netlib`, including run-time and
3+
compile-time.

‎libs/network/doc/conf.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,9 @@
5454
# built documents.
5555
#
5656
# The short X.Y version.
57-
version='0.7'
57+
version='0.8'
5858
# The full version, including alpha/beta/rc tags.
59-
release='0.7'
59+
release='0.8'
6060

6161
# The language for content autogenerated by Sphinx. Refer to documentation
6262
# for a list of supported languages.

‎libs/network/doc/index.rst‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212

1313
.. :Authors: Glyn Matthews <glyn.matthews@gmail.com>
1414
.. Dean Michael Berris <mikhailberis@gmail.com>
15-
.. :Date:Oct 9, 2010
16-
.. :Version: 0.7
15+
.. :Date:Nov 1, 2010
16+
.. :Version: 0.8
1717
.. :Description: Complete user documentation, with examples, for the :mod:`cpp-netlib`.
1818
.. :Copyright: Copyright Glyn Matthews, Dean Michael Berris 2008-2010.
1919
.. Distributed under the Boost Software License, Version
@@ -37,7 +37,7 @@ Sneak Peak
3737
----------
3838

3939
The:mod:`cpp-netlib` allows you to write semantically consistent code for
40-
making different kinds of higher level network applications.
40+
making different kinds of higher level network applications.
4141

4242
The library allows for writing simple code for simple C++ HTTP client
4343
applications like:

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp