ThreadSchedule 3.0.0
Modern C++ thread management library
Loading...
Searching...
No Matches
threadschedule::thread_id Class Reference

#include <thread_id.hpp>

Public Member Functions

constexpr thread_id (std::int64_t value)
 Construct and validate a thread id.
 

Static Public Member Functions

static auto create (std::int64_t value) noexcept -> result< thread_id >
 Construct a thread id without exceptions.
 

Friends

struct detail::thread_id_access
 
constexpr auto operator== (thread_id lhs, thread_id rhs) noexcept -> bool
 
constexpr auto operator!= (thread_id lhs, thread_id rhs) noexcept -> bool
 
constexpr auto operator< (thread_id lhs, thread_id rhs) noexcept -> bool
 

Detailed Description

Definition at line 21 of file thread_id.hpp.

Constructor & Destructor Documentation

◆ thread_id()

constexpr threadschedule::thread_id::thread_id ( std::int64_t  value)
inlineexplicitconstexpr

Construct and validate a thread id.

Parameters
valuePositive numeric thread id.
Exceptions
std::invalid_argumentif value is not positive.

Definition at line 29 of file thread_id.hpp.

Member Function Documentation

◆ create()

static auto threadschedule::thread_id::create ( std::int64_t  value) -> result<thread_id>
inlinestaticnoexcept

Construct a thread id without exceptions.

Parameters
valuePositive numeric thread id.
Returns
A valid thread_id or errc::invalid_argument.

Definition at line 37 of file thread_id.hpp.

Friends And Related Symbol Documentation

◆ detail::thread_id_access

friend struct detail::thread_id_access
friend

Definition at line 61 of file thread_id.hpp.

◆ operator!=

constexpr auto operator!= ( thread_id  lhs,
thread_id  rhs 
) -> bool
friend

Definition at line 50 of file thread_id.hpp.

◆ operator<

constexpr auto operator< ( thread_id  lhs,
thread_id  rhs 
) -> bool
friend

Definition at line 54 of file thread_id.hpp.

◆ operator==

constexpr auto operator== ( thread_id  lhs,
thread_id  rhs 
) -> bool
friend

Definition at line 45 of file thread_id.hpp.


The documentation for this class was generated from the following file: