OpenPit C++ SDK
C++17 SDK for the OpenPit pre-trade risk engine
openpit::asyncengine::PairFuture< A, B > Class Template Reference

Consumer side of an async operation returning two values. More...

Public Member Functions

std::pair< A, B > Await () const
 
template<typename Rep , typename Period >
std::optional< std::pair< A, B > > Await (std::chrono::duration< Rep, Period > timeout) const
 
bool Done () const
 
 PairFuture ()=default
 
 PairFuture (Future< std::pair< A, B >> inner)
 

Detailed Description

template<typename A, typename B>
class openpit::asyncengine::PairFuture< A, B >

Consumer side of an async operation returning two values.

Constructor & Destructor Documentation

◆ PairFuture() [1/2]

template<typename A , typename B >
openpit::asyncengine::PairFuture< A, B >::PairFuture ( )
default

◆ PairFuture() [2/2]

template<typename A , typename B >
openpit::asyncengine::PairFuture< A, B >::PairFuture ( Future< std::pair< A, B >>  inner)
inlineexplicit

Member Function Documentation

◆ Await() [1/2]

template<typename A , typename B >
std::pair<A, B> openpit::asyncengine::PairFuture< A, B >::Await ( ) const
inline

◆ Await() [2/2]

template<typename A , typename B >
template<typename Rep , typename Period >
std::optional<std::pair<A, B> > openpit::asyncengine::PairFuture< A, B >::Await ( std::chrono::duration< Rep, Period >  timeout) const
inline

◆ Done()

template<typename A , typename B >
bool openpit::asyncengine::PairFuture< A, B >::Done ( ) const
inline