zpp
Zephyr C++20 Framework
|
Thread priority. More...
#include <thread_prio.hpp>
Public Member Functions | |
constexpr | thread_prio () noexcept |
Default constructor initializing priority to zero. More... | |
constexpr | thread_prio (int prio) noexcept |
Constructor initializing priority to prio. More... | |
constexpr int | native_value () const noexcept |
Get the Zephyr native priority value. More... | |
Static Public Member Functions | |
static constexpr thread_prio | highest_coop () noexcept |
Get the most prior cooperative priority. More... | |
static constexpr thread_prio | lowest_coop () noexcept |
Get the least prior cooperative priority. More... | |
static constexpr thread_prio | highest_preempt () noexcept |
Get the most prior preemptive priority. More... | |
static constexpr thread_prio | lowest_preempt () noexcept |
Get the least prior preemptive priority. More... | |
static constexpr thread_prio | min_coop_numeric () noexcept |
Get the minium coop numeric value. More... | |
static constexpr thread_prio | max_coop_numeric () noexcept |
Get the minium coop numeric value. More... | |
static constexpr thread_prio | min_preempt_numeric () noexcept |
Get the minium preempt numeric value. More... | |
static constexpr thread_prio | max_preempt_numeric () noexcept |
Get the minium preempt numeric value. More... | |
static constexpr thread_prio | min_numeric () noexcept |
Get the minium numeric value. More... | |
static constexpr thread_prio | max_numeric () noexcept |
Get the maxium numeric value. More... | |
static constexpr thread_prio | coop (int prio) noexcept |
Create a cooperative priority value. More... | |
static constexpr thread_prio | preempt (int prio) noexcept |
Create a preemptive priority value. More... | |
Thread priority.
Definition at line 18 of file thread_prio.hpp.
|
inlineconstexprnoexcept |
Default constructor initializing priority to zero.
Definition at line 23 of file thread_prio.hpp.
Referenced by coop(), highest_coop(), highest_preempt(), lowest_coop(), lowest_preempt(), and preempt().
|
inlineexplicitconstexprnoexcept |
Constructor initializing priority to prio.
prio | The priority value to use for initialization |
Definition at line 32 of file thread_prio.hpp.
|
inlinestaticconstexprnoexcept |
Create a cooperative priority value.
prio | the value, from 0 to highest_coop |
Definition at line 174 of file thread_prio.hpp.
References thread_prio(), lowest_coop(), and native_value().
|
inlinestaticconstexprnoexcept |
Get the most prior cooperative priority.
Definition at line 59 of file thread_prio.hpp.
References thread_prio().
Referenced by min_coop_numeric().
|
inlinestaticconstexprnoexcept |
Get the most prior preemptive priority.
Definition at line 79 of file thread_prio.hpp.
References thread_prio().
Referenced by min_preempt_numeric(), and preempt().
|
inlinestaticconstexprnoexcept |
Get the least prior cooperative priority.
Definition at line 69 of file thread_prio.hpp.
References thread_prio().
Referenced by coop(), and max_coop_numeric().
|
inlinestaticconstexprnoexcept |
Get the least prior preemptive priority.
Definition at line 89 of file thread_prio.hpp.
References thread_prio().
Referenced by max_preempt_numeric(), and preempt().
|
inlinestaticconstexprnoexcept |
Get the minium coop numeric value.
The maxium coop numric value is the lowest coop thread priority
Definition at line 115 of file thread_prio.hpp.
References lowest_coop().
|
inlinestaticconstexprnoexcept |
Get the maxium numeric value.
Definition at line 161 of file thread_prio.hpp.
References max_preempt_numeric().
|
inlinestaticconstexprnoexcept |
Get the minium preempt numeric value.
The maxium coop numric value is the lowest thread priority
Definition at line 141 of file thread_prio.hpp.
References lowest_preempt().
Referenced by max_numeric().
|
inlinestaticconstexprnoexcept |
Get the minium coop numeric value.
The minium coop numric value is the highest thread priority
Definition at line 102 of file thread_prio.hpp.
References highest_coop().
Referenced by min_numeric().
|
inlinestaticconstexprnoexcept |
Get the minium numeric value.
Definition at line 151 of file thread_prio.hpp.
References min_coop_numeric().
|
inlinestaticconstexprnoexcept |
Get the minium preempt numeric value.
The minium preempt numric value is the highest preempt thread priority
Definition at line 128 of file thread_prio.hpp.
References highest_preempt().
|
inlineconstexprnoexcept |
Get the Zephyr native priority value.
Definition at line 49 of file thread_prio.hpp.
Referenced by coop(), zpp::thread_attr::native_prio(), and preempt().
|
inlinestaticconstexprnoexcept |
Create a preemptive priority value.
prio | the value, from 0 to highest_preempt |
Definition at line 186 of file thread_prio.hpp.
References thread_prio(), highest_preempt(), lowest_preempt(), and native_value().