roo_threads
API Documentation for roo_threads
Loading...
Searching...
No Matches

Thread and current-thread utilities. More...

Collaboration diagram for Thread:

Data Structures

class  roo_threads::doc::thread
 Canonical documentation-only thread API. More...
 

Functions

thread::id roo_threads::doc::this_thread::get_id () noexcept
 Returns identifier of the current thread.
 
void roo_threads::doc::this_thread::yield () noexcept
 Hints the scheduler to run another thread.
 
void roo_threads::doc::this_thread::sleep_for (const roo_time::Duration &duration)
 Blocks the current thread for at least the given duration.
 
void roo_threads::doc::this_thread::sleep_until (const roo_time::Uptime &when)
 Blocks the current thread until the specified time point.
 

Detailed Description

Thread and current-thread utilities.

Function Documentation

◆ get_id()

thread::id roo_threads::doc::this_thread::get_id ( )
noexcept

Returns identifier of the current thread.

◆ sleep_for()

void roo_threads::doc::this_thread::sleep_for ( const roo_time::Duration &  duration)

Blocks the current thread for at least the given duration.

Parameters
durationsleep interval.

◆ sleep_until()

void roo_threads::doc::this_thread::sleep_until ( const roo_time::Uptime &  when)

Blocks the current thread until the specified time point.

Parameters
whenwake-up time.

◆ yield()

void roo_threads::doc::this_thread::yield ( )
noexcept

Hints the scheduler to run another thread.