]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/boost/winapi/priority_class.hpp
update sources to v12.2.3
[ceph.git] / ceph / src / boost / boost / winapi / priority_class.hpp
1 /*
2 * Copyright 2016 Klemens D. Morgenstern
3 * Copyright 2016 Andrey Semashev
4 *
5 * Distributed under the Boost Software License, Version 1.0.
6 * See http://www.boost.org/LICENSE_1_0.txt
7 */
8
9 #ifndef BOOST_WINAPI_PRIORITY_CLASS_HPP_INCLUDED_
10 #define BOOST_WINAPI_PRIORITY_CLASS_HPP_INCLUDED_
11
12 #include <boost/winapi/basic_types.hpp>
13
14 #ifdef BOOST_HAS_PRAGMA_ONCE
15 #pragma once
16 #endif
17
18 #if BOOST_WINAPI_PARTITION_DESKTOP_SYSTEM
19
20 #if !defined( BOOST_USE_WINDOWS_H )
21 extern "C" {
22
23 BOOST_SYMBOL_IMPORT boost::winapi::DWORD_ WINAPI
24 GetPriorityClass(boost::winapi::HANDLE_ hProcess);
25
26 BOOST_SYMBOL_IMPORT boost::winapi::BOOL_ WINAPI
27 SetPriorityClass(
28 boost::winapi::HANDLE_ hProcess,
29 boost::winapi::DWORD_ dwPriorityClass);
30
31 } // extern "C"
32 #endif //defined BOOST_WINDOWS_H
33
34 namespace boost {
35 namespace winapi {
36
37 #if defined(BOOST_USE_WINDOWS_H)
38
39 const DWORD_ NORMAL_PRIORITY_CLASS_ = NORMAL_PRIORITY_CLASS;
40 const DWORD_ IDLE_PRIORITY_CLASS_ = IDLE_PRIORITY_CLASS;
41 const DWORD_ HIGH_PRIORITY_CLASS_ = HIGH_PRIORITY_CLASS;
42 const DWORD_ REALTIME_PRIORITY_CLASS_ = REALTIME_PRIORITY_CLASS;
43 const DWORD_ BELOW_NORMAL_PRIORITY_CLASS_ = BELOW_NORMAL_PRIORITY_CLASS;
44 const DWORD_ ABOVE_NORMAL_PRIORITY_CLASS_ = ABOVE_NORMAL_PRIORITY_CLASS;
45
46 #if BOOST_USE_WINAPI_VERSION >= BOOST_WINAPI_VERSION_WIN6
47 const DWORD_ PROCESS_MODE_BACKGROUND_BEGIN_ = PROCESS_MODE_BACKGROUND_BEGIN;
48 const DWORD_ PROCESS_MODE_BACKGROUND_END_ = PROCESS_MODE_BACKGROUND_END;
49 #endif
50
51 #else // defined( BOOST_USE_WINDOWS_H )
52
53 const DWORD_ NORMAL_PRIORITY_CLASS_ = 0x20;
54 const DWORD_ IDLE_PRIORITY_CLASS_ = 0x40;
55 const DWORD_ HIGH_PRIORITY_CLASS_ = 0x80;
56 const DWORD_ REALTIME_PRIORITY_CLASS_ = 0x100;
57 const DWORD_ BELOW_NORMAL_PRIORITY_CLASS_ = 0x4000;
58 const DWORD_ ABOVE_NORMAL_PRIORITY_CLASS_ = 0x8000;
59
60 #if BOOST_USE_WINAPI_VERSION >= BOOST_WINAPI_VERSION_WIN6
61 const DWORD_ PROCESS_MODE_BACKGROUND_BEGIN_ = 0x100000;
62 const DWORD_ PROCESS_MODE_BACKGROUND_END_ = 0x200000;
63 #endif
64
65 #endif // defined( BOOST_USE_WINDOWS_H )
66
67 using ::GetPriorityClass;
68 using ::SetPriorityClass;
69
70 }
71 }
72
73 #endif // BOOST_WINAPI_PARTITION_DESKTOP_SYSTEM
74
75 #endif // BOOST_WINAPI_PRIORITY_CLASS_HPP_INCLUDED_