File tree Expand file tree Collapse file tree 14 files changed +56
-42
lines changed Expand file tree Collapse file tree 14 files changed +56
-42
lines changed Original file line number Diff line number Diff line change @@ -59,7 +59,14 @@ elseif(ANDROID)
59
59
elseif (UNIX ) # This includes OSX
60
60
find_package (Boost REQUIRED COMPONENTS random chrono system thread locale regex filesystem )
61
61
find_package (Threads REQUIRED )
62
- find_package (OpenSSL REQUIRED )
62
+ if (APPLE AND NOT OPENSSL_ROOT_DIR )
63
+ # Prefer a homebrew version of OpenSSL over the one in /usr/lib
64
+ file (GLOB OPENSSL_ROOT_DIR /usr/local/Cellar/openssl/* )
65
+ # Prefer the latest (make the latest one first)
66
+ list (REVERSE OPENSSL_ROOT_DIR )
67
+ endif ()
68
+ # This should prevent linking against the system provided 0.9.8y
69
+ find_package (OpenSSL 1.0.0 REQUIRED )
63
70
64
71
option (BUILD_SHARED_LIBS "Build shared Libraries." ON )
65
72
option (BUILD_TESTS "Build tests." ON )
Original file line number Diff line number Diff line change @@ -96,7 +96,10 @@ namespace std {
96
96
}
97
97
#endif // _MS_WINDOWS
98
98
99
- namespace Concurrency { namespace streams
99
+ namespace Concurrency
100
+ {
101
+ // / Library for asychronous streams.
102
+ namespace streams
100
103
{
101
104
// / <summary>
102
105
// / Extending the standard char_traits type with one that adds values and types
Original file line number Diff line number Diff line change @@ -50,27 +50,14 @@ namespace pplx = Concurrency;
50
50
#include < boost/algorithm/string.hpp>
51
51
#endif
52
52
53
+ // / Various utilities for string conversions and date and time manipulation.
53
54
namespace utility
54
55
{
55
56
56
- # if !defined(_MS_WINDOWS) || (_MSC_VER >= 1700) // Post VS10 and Linux
57
+ // Left over from VS2010 support, remains to avoid breaking.
57
58
typedef std::chrono::seconds seconds;
58
- #else // VS10
59
- // / <summary>
60
- // / A type used to represent timeouts for Azure storage APIs
61
- // / </summary>
62
- // The chrono header is not present on Visual Studio with versions < 1700 so we define a 'seconds' type for timeouts
63
- class seconds
64
- {
65
- public:
66
- explicit seconds (__int64 time = 0 ): m_count(time) {}
67
- __int64 count () const { return m_count; }
68
-
69
- private:
70
- __int64 m_count;
71
- };
72
- #endif
73
59
60
+ // / Functions for converting to/from std::chrono::seconds to xml string.
74
61
namespace timespan
75
62
{
76
63
// / <summary>
@@ -86,6 +73,7 @@ namespace timespan
86
73
_ASYNCRTIMP utility::seconds __cdecl xml_duration_to_seconds (utility::string_t timespanString);
87
74
}
88
75
76
+ // / Functions for string conversions.
89
77
namespace conversions
90
78
{
91
79
// / <summary>
Original file line number Diff line number Diff line change @@ -316,6 +316,7 @@ namespace web {
316
316
// / A default port is one where the port is unspecified, and will be determined by the operating system.
317
317
// / The choice of default port may be dictated by the scheme (http -> 80) or not.
318
318
// / </summary>
319
+ // / <returns><c>true</c> if this URI instance has a default port, <c>false</c> otherwise.</returns>
319
320
bool is_port_default () const
320
321
{
321
322
return !is_empty () && this ->port () == 0 ;
Original file line number Diff line number Diff line change @@ -100,7 +100,7 @@ namespace details {
100
100
101
101
// / <summary>
102
102
// / Private stream buffer implementation for file streams.
103
- // / The class itself should not be used in application code, it is used by the stream definitions farther down in the header file.
103
+ // / The class itself should not be used in application code, it is used by the stream definitions farther down in the header file.
104
104
// / </summary>
105
105
template <typename _CharType>
106
106
class basic_file_buffer : public details ::streambuf_state_manager<_CharType>
Original file line number Diff line number Diff line change @@ -65,10 +65,13 @@ namespace pplx = Concurrency;
65
65
66
66
#include " cpprest/oauth2.h"
67
67
68
+ // / The web namespace contains functionality common to multiple protocols like HTTP and WebSockets.
68
69
namespace web
69
70
{
71
+ // / Declarations and functionality for the HTTP protocol.
70
72
namespace http
71
73
{
74
+ // / HTTP client side library.
72
75
namespace client
73
76
{
74
77
@@ -263,7 +266,7 @@ class http_client_config
263
266
// / <summary>
264
267
// / Sets the server certificate validation property.
265
268
// / </summary>
266
- // / <param name="validate_cert ">False to turn ignore all server certificate validation errors, true otherwise.</param>
269
+ // / <param name="validate_certs ">False to turn ignore all server certificate validation errors, true otherwise.</param>
267
270
// / <remarks>Note ignoring certificate errors can be dangerous and should be done with caution.</remarks>
268
271
void set_validate_certificates (bool validate_certs)
269
272
{
Original file line number Diff line number Diff line change 37
37
38
38
#include " cpprest/http_msg.h"
39
39
40
- namespace web {
41
-
42
- // / <summary>
43
- // / Declaration to avoid making a dependency on IISHost.
44
- // / </summary>
45
- namespace iis_host
46
- {
47
- class http_iis_receiver ;
48
- }
49
-
40
+ namespace web
41
+ {
50
42
namespace http
51
43
{
52
- namespace experimental {
44
+ // / HTTP listener is currently in beta.
45
+ namespace experimental
46
+ {
47
+ // / HTTP server side library.
53
48
namespace listener
54
49
{
55
50
Original file line number Diff line number Diff line change @@ -51,18 +51,11 @@ namespace pplx = Concurrency;
51
51
#include < boost/algorithm/string/predicate.hpp>
52
52
#endif
53
53
54
- namespace web {
55
-
56
- // / <summary>
57
- // / Declaration to avoid making a dependency on IISHost.
58
- // / </summary>
59
- namespace iis_host
54
+ namespace web
60
55
{
61
- class http_iis_receiver ;
62
- }
63
-
64
56
namespace http
65
57
{
58
+
66
59
// URI class has been moved from web::http namespace to web namespace.
67
60
// The below using declarations ensure we dont break existing code.
68
61
// Please use the web::uri class going forward.
@@ -79,6 +72,10 @@ namespace client
79
72
// / HTTP 1.1 specification.
80
73
// / </summary>
81
74
typedef utility::string_t method;
75
+
76
+ // / <summary>
77
+ // / Common HTTP methods.
78
+ // / </summary>
82
79
class methods
83
80
{
84
81
public:
@@ -191,6 +188,10 @@ class http_exception : public std::exception
191
188
return m_msg.c_str ();
192
189
}
193
190
191
+ // / <summary>
192
+ // / Retrieves the underlying error code causing this exception.
193
+ // / </summary>
194
+ // / <returns>A std::error_code.</returns>
194
195
const std::error_code & error_code () const
195
196
{
196
197
return m_errorCode;
Original file line number Diff line number Diff line change 39
39
#include " cpprest/basic_types.h"
40
40
#include " cpprest/asyncrt_utils.h"
41
41
42
- namespace web { namespace json
42
+ namespace web
43
+ {
44
+ // / Library for parsing and serializing JSON values to and from C++ types.
45
+ namespace json
43
46
{
44
47
45
48
// Various forward declarations.
Original file line number Diff line number Diff line change @@ -35,6 +35,7 @@ namespace web
35
35
{
36
36
namespace http
37
37
{
38
+ // / oAuth 1.0 library.
38
39
namespace oauth1
39
40
{
40
41
namespace details
@@ -91,6 +92,7 @@ class oauth1_strings
91
92
92
93
} // namespace web::http::oauth1::details
93
94
95
+ // / oAuth functionality is currently in beta.
94
96
namespace experimental
95
97
{
96
98
You can’t perform that action at this time.
0 commit comments