modm API documentation
modm::fiber::barrier< CompletionFunction > Class Template Reference

#include <modm/processing/fiber/barrier.hpp>

Public Typedefs

using arrival_token = count_t
 

Public Member Functions

constexpr barrier (std::ptrdiff_t expected, CompletionFunction f=CompletionFunction ())
 
arrival_token arrive (count_t n=1)
 
void wait (arrival_token arrival) const
 
void arrive_and_wait ()
 
void arrive_and_drop ()
 

Static Public Member Functions

static constexpr std::ptrdiff_t max ()
 

Detailed Description

template<class CompletionFunction = decltype([]{})>
class modm::fiber::barrier< CompletionFunction >

Implements the std::barrier interface for fibers.

Warning
This implementation is not interrupt-safe!
See also
https://en.cppreference.com/w/cpp/thread/barrier

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