]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/exception/include/boost/exception/detail/error_info_impl.hpp
bump version to 12.2.2-pve1
[ceph.git] / ceph / src / boost / libs / exception / include / boost / exception / detail / error_info_impl.hpp
1 //Copyright (c) 2006-2010 Emil Dotchevski and Reverge Studios, Inc.
2
3 //Distributed under the Boost Software License, Version 1.0. (See accompanying
4 //file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
5
6 #ifndef UUID_CE6983AC753411DDA764247956D89593
7 #define UUID_CE6983AC753411DDA764247956D89593
8 #if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
9 #pragma GCC system_header
10 #endif
11 #if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
12 #pragma warning(push,1)
13 #endif
14
15 #include <boost/config.hpp>
16 #include <utility>
17 #include <string>
18
19 namespace
20 boost
21 {
22 namespace
23 exception_detail
24 {
25 class
26 error_info_base
27 {
28 public:
29
30 virtual std::string name_value_string() const = 0;
31
32 protected:
33
34 virtual
35 ~error_info_base() throw()
36 {
37 }
38 };
39 }
40
41 template <class Tag,class T>
42 class
43 error_info:
44 public exception_detail::error_info_base
45 {
46 public:
47
48 typedef T value_type;
49
50 error_info( value_type const & value );
51 #ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
52 error_info( error_info const & );
53 error_info( value_type && value ) BOOST_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(value_type(std::move(value))));
54 error_info( error_info && x ) BOOST_NOEXCEPT_IF(BOOST_NOEXCEPT_EXPR(value_type(std::move(x.value_))));
55 #endif
56 ~error_info() throw();
57
58 value_type const &
59 value() const
60 {
61 return value_;
62 }
63
64 value_type &
65 value()
66 {
67 return value_;
68 }
69
70 private:
71 error_info & operator=( error_info const & );
72 #ifndef BOOST_NO_CXX11_RVALUE_REFERENCES
73 error_info & operator=( error_info && x );
74 #endif
75
76 std::string name_value_string() const;
77
78 value_type value_;
79 };
80 }
81
82 #if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
83 #pragma warning(pop)
84 #endif
85 #endif