1 // Copyright (C) 2001-2003
3 // Copyright (C) 2007-8 Anthony Williams
5 // Distributed under the Boost Software License, Version 1.0. (See accompanying
6 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
8 #ifndef BOOST_THREAD_EXCEPTIONS_PDM070801_H
9 #define BOOST_THREAD_EXCEPTIONS_PDM070801_H
11 #include <boost/thread/detail/config.hpp>
13 // pdm: Sorry, but this class is used all over the place & I end up
14 // with recursive headers if I don't separate it
15 // wek: Not sure why recursive headers would cause compilation problems
16 // given the include guards, but regardless it makes sense to
17 // seperate this out any way.
22 #include <boost/config/abi_prefix.hpp>
27 class BOOST_THREAD_DECL thread_interrupted
30 class BOOST_THREAD_DECL thread_exception
: public std::exception
34 thread_exception(int sys_err_code
);
37 ~thread_exception() throw();
39 int native_error() const;
45 class condition_error
:
49 const char* what() const throw()
51 return "Condition error";
56 class BOOST_THREAD_DECL lock_error
: public thread_exception
60 lock_error(int sys_err_code
);
61 ~lock_error() throw();
63 virtual const char* what() const throw();
66 class BOOST_THREAD_DECL thread_resource_error
: public thread_exception
69 thread_resource_error();
70 thread_resource_error(int sys_err_code
);
71 ~thread_resource_error() throw();
73 virtual const char* what() const throw();
76 class BOOST_THREAD_DECL unsupported_thread_option
: public thread_exception
79 unsupported_thread_option();
80 unsupported_thread_option(int sys_err_code
);
81 ~unsupported_thread_option() throw();
83 virtual const char* what() const throw();
86 class BOOST_THREAD_DECL invalid_thread_argument
: public thread_exception
89 invalid_thread_argument();
90 invalid_thread_argument(int sys_err_code
);
91 ~invalid_thread_argument() throw();
93 virtual const char* what() const throw();
96 class BOOST_THREAD_DECL thread_permission_error
: public thread_exception
99 thread_permission_error();
100 thread_permission_error(int sys_err_code
);
101 ~thread_permission_error() throw();
103 virtual const char* what() const throw();
108 #include <boost/config/abi_suffix.hpp>
110 #endif // BOOST_THREAD_CONFIG_PDM070801_H
113 // 3 Jan 03 WEKEMPF Modified for DLL implementation.