hamcast  Version 0.7
Public Member Functions | List of all members
hamcast::util::future< T > Class Template Reference

#include <future.hpp>

Public Member Functions

T & get ()
 
void set (const T &val)
 

Detailed Description

template<typename T>
class hamcast::util::future< T >

Describes a simple synchronous future value.

Member Function Documentation

template<typename T >
T& hamcast::util::future< T >::get ( )

Read the produced value.

Returns
A reference to the produced value.
Warning
This function blocks until set was called.
template<typename T >
void hamcast::util::future< T >::set ( const T &  val)

Set the value to val and wakeup waiting consumer thread.

Parameters
valThe produced value.

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