YACLib
C++ library for concurrent tasks execution
Loading...
Searching...
No Matches
yaclib::when Namespace Reference

Classes

struct  All
 
struct  All< FailPolicy::FirstFail, OutputValue, OutputError, InputCore >
 
struct  All< FailPolicy::None, OutputValue, OutputError, InputCore >
 
struct  AllTuple
 
struct  AllTuple< FailPolicy::FirstFail, OutputValue, OutputError, InputCore >
 
struct  AllTuple< FailPolicy::None, OutputValue, OutputError, InputCore >
 
struct  Any
 
struct  Any< FailPolicy::FirstFail, OutputValue, OutputError, InputCore >
 
struct  Any< FailPolicy::LastFail, OutputValue, OutputError, InputCore >
 
struct  Any< FailPolicy::None, OutputValue, OutputError, InputCore >
 
struct  CombinatorCallback
 
struct  CoreSignature
 
struct  DynamicCombinator
 
struct  Join
 
struct  Join< FailPolicy::FirstFail, void, OutputError, InputCore >
 
struct  Join< FailPolicy::None, void, OutputError, InputCore >
 
struct  SingleCombinator
 
struct  StaticCombinator
 

Typedefs

template<typename T >
using IsUniqueCore = detail::IsInstantiationOf< detail::UniqueCore, T >
 
template<typename T >
using IsSharedCore = detail::IsInstantiationOf< detail::SharedCore, T >
 

Functions

template<typename... Futures>
YACLIB_INLINE void CheckSameError ()
 
template<typename Strategy , typename Core >
YACLIB_INLINE void ConsumeImpl (Strategy &st, Core &core)
 
template<std::size_t Index, typename Strategy , typename Core >
YACLIB_INLINE void ConsumeImpl (Strategy &st, Core &core)
 
template<typename Strategy , typename Core >
YACLIB_INLINE void ConsumeImpl (Strategy &st, Core &core, std::size_t index)
 
template<std::size_t Index, typename Strategy , typename Core >
YACLIB_INLINE void Consume (Strategy &st, Core &core)
 
template<typename Strategy , typename Core >
YACLIB_INLINE void Consume (Strategy &st, Core &core, std::size_t index)
 
template<template< FailPolicy, typename... > typename Strategy, FailPolicy F, typename OutputValue , typename OutputError , typename... Futures>
auto When (Futures... futures)
 
template<template< FailPolicy, typename... > typename Strategy, FailPolicy F, typename OutputValue , typename OutputError , typename Iterator , typename Value = typename std::iterator_traits<Iterator>::value_type>
auto When (Iterator begin, std::size_t count)
 

Variables

template<ConsumePolicy P>
constexpr bool kIsOrdered = P == ConsumePolicy::Static || P == ConsumePolicy::Dynamic
 
constexpr std::size_t kDynamicTag = std::numeric_limits<std::size_t>::max()
 

Typedef Documentation

◆ IsSharedCore

◆ IsUniqueCore

Function Documentation

◆ CheckSameError()

template<typename... Futures>
YACLIB_INLINE void yaclib::when::CheckSameError ( )

Definition at line 20 of file when.hpp.

References yaclib::Error, and yaclib::MakeContract().

Referenced by yaclib::Join(), yaclib::WhenAll(), and yaclib::WhenAny().

◆ Consume() [1/2]

template<std::size_t Index, typename Strategy , typename Core >
YACLIB_INLINE void yaclib::when::Consume ( Strategy &  st,
Core &  core 
)

◆ Consume() [2/2]

template<typename Strategy , typename Core >
YACLIB_INLINE void yaclib::when::Consume ( Strategy &  st,
Core &  core,
std::size_t  index 
)

Definition at line 81 of file when.hpp.

References ConsumeImpl(), yaclib::Managed, yaclib::None, yaclib::Static, and yaclib::Unordered.

◆ ConsumeImpl() [1/3]

template<typename Strategy , typename Core >
YACLIB_INLINE void yaclib::when::ConsumeImpl ( Strategy &  st,
Core &  core 
)

Definition at line 39 of file when.hpp.

References yaclib::Owned.

Referenced by Consume(), and Consume().

◆ ConsumeImpl() [2/3]

template<std::size_t Index, typename Strategy , typename Core >
YACLIB_INLINE void yaclib::when::ConsumeImpl ( Strategy &  st,
Core &  core 
)

Definition at line 48 of file when.hpp.

References yaclib::MakeContract(), and yaclib::Owned.

◆ ConsumeImpl() [3/3]

template<typename Strategy , typename Core >
YACLIB_INLINE void yaclib::when::ConsumeImpl ( Strategy &  st,
Core &  core,
std::size_t  index 
)

Definition at line 57 of file when.hpp.

References yaclib::Owned.

◆ When() [1/2]

template<template< FailPolicy, typename... > typename Strategy, FailPolicy F, typename OutputValue , typename OutputError , typename... Futures>
auto yaclib::when::When ( Futures...  futures)

◆ When() [2/2]

template<template< FailPolicy, typename... > typename Strategy, FailPolicy F, typename OutputValue , typename OutputError , typename Iterator , typename Value = typename std::iterator_traits<Iterator>::value_type>
auto yaclib::when::When ( Iterator  begin,
std::size_t  count 
)

Definition at line 349 of file when.hpp.

References yaclib::when::DynamicCombinator< Strategy, Core >::Set(), and When().

Variable Documentation

◆ kDynamicTag

constexpr std::size_t yaclib::when::kDynamicTag = std::numeric_limits<std::size_t>::max()
inlineconstexpr

Definition at line 36 of file when.hpp.

◆ kIsOrdered

template<ConsumePolicy P>
constexpr bool yaclib::when::kIsOrdered = P == ConsumePolicy::Static || P == ConsumePolicy::Dynamic
inlineconstexpr

Definition at line 34 of file when.hpp.