PageRenderTime 22ms CodeModel.GetById 13ms app.highlight 5ms RepoModel.GetById 2ms app.codeStats 0ms

/Src/Dependencies/Boost/boost/asio/ssl/error.hpp

http://hadesmem.googlecode.com/
C++ Header | 72 lines | 45 code | 18 blank | 9 comment | 1 complexity | 222c6b61deb6417fc28e41e16cbf9f95 MD5 | raw file
 1//
 2// ssl/error.hpp
 3// ~~~~~~~~~~~~~
 4//
 5// Copyright (c) 2003-2011 Christopher M. Kohlhoff (chris at kohlhoff dot com)
 6//
 7// Distributed under the Boost Software License, Version 1.0. (See accompanying
 8// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
 9//
10
11#ifndef BOOST_ASIO_SSL_ERROR_HPP
12#define BOOST_ASIO_SSL_ERROR_HPP
13
14#if defined(_MSC_VER) && (_MSC_VER >= 1200)
15# pragma once
16#endif // defined(_MSC_VER) && (_MSC_VER >= 1200)
17
18#include <boost/asio/detail/config.hpp>
19#include <boost/system/error_code.hpp>
20
21#include <boost/asio/detail/push_options.hpp>
22
23namespace boost {
24namespace asio {
25namespace error {
26
27enum ssl_errors
28{
29};
30
31extern BOOST_ASIO_DECL
32const boost::system::error_category& get_ssl_category();
33
34static const boost::system::error_category& ssl_category
35  = boost::asio::error::get_ssl_category();
36
37} // namespace error
38} // namespace asio
39} // namespace boost
40
41namespace boost {
42namespace system {
43
44template<> struct is_error_code_enum<boost::asio::error::ssl_errors>
45{
46  static const bool value = true;
47};
48
49} // namespace system
50} // namespace boost
51
52namespace boost {
53namespace asio {
54namespace error {
55
56inline boost::system::error_code make_error_code(ssl_errors e)
57{
58  return boost::system::error_code(
59      static_cast<int>(e), get_ssl_category());
60}
61
62} // namespace error
63} // namespace asio
64} // namespace boost
65
66#include <boost/asio/detail/pop_options.hpp>
67
68#if defined(BOOST_ASIO_HEADER_ONLY)
69# include <boost/asio/ssl/impl/error.ipp>
70#endif // defined(BOOST_ASIO_HEADER_ONLY)
71
72#endif // BOOST_ASIO_SSL_ERROR_HPP