hpx/lcos_local/receive_buffer.hpp

See Public API for a list of names and headers that are part of the public HPX API.

namespace hpx
namespace lcos
namespace local
template<typename T, typename Mutex = hpx::spinlock>
struct receive_buffer

Public Functions

receive_buffer()
receive_buffer(receive_buffer &&other)
~receive_buffer()
receive_buffer &operator=(receive_buffer &&other)
hpx::future<T> receive(std::size_t step)
bool try_receive(std::size_t step, hpx::future<T> *f = nullptr)
template<typename Lock = hpx::no_mutex>
void store_received(std::size_t step, T &&val, Lock *lock = nullptr)
bool empty() const
std::size_t cancel_waiting(std::exception_ptr const &e, bool force_delete_entries = false)

Protected Types

typedef Mutex mutex_type
typedef hpx::promise<T> buffer_promise_type
typedef std::map<std::size_t, std::shared_ptr<entry_data>> buffer_map_type
typedef buffer_map_type::iterator iterator

Protected Functions

iterator get_buffer_entry(std::size_t step)

Private Members

mutex_type mtx_
buffer_map_type buffer_map_
struct entry_data

Public Functions

template<>
HPX_NON_COPYABLE(entry_data)
template<>
entry_data()
template<>
hpx::future<T> get_future()
template<typename Val>
void set_value(Val &&val)
template<>
bool cancel(std::exception_ptr const &e)

Public Members

template<>
buffer_promise_type promise_
template<>
bool can_be_deleted_
template<>
bool value_set_
struct erase_on_exit

Public Functions

template<>
erase_on_exit(buffer_map_type &buffer_map, iterator it)
template<>
~erase_on_exit()

Public Members

template<>
buffer_map_type &buffer_map_
template<>
iterator it_
template<typename Mutex>
struct receive_buffer<void, Mutex>

Public Functions

receive_buffer()
receive_buffer(receive_buffer &&other)
~receive_buffer()
receive_buffer &operator=(receive_buffer &&other)
hpx::future<void> receive(std::size_t step)
bool try_receive(std::size_t step, hpx::future<void> *f = nullptr)
template<typename Lock = hpx::no_mutex>
void store_received(std::size_t step, Lock *lock = nullptr)
bool empty() const
std::size_t cancel_waiting(std::exception_ptr const &e, bool force_delete_entries = false)

Protected Types

typedef Mutex mutex_type
typedef hpx::promise<void> buffer_promise_type
typedef std::map<std::size_t, std::shared_ptr<entry_data>> buffer_map_type
typedef buffer_map_type::iterator iterator

Protected Functions

iterator get_buffer_entry(std::size_t step)

Private Members

mutex_type mtx_
buffer_map_type buffer_map_
template<>
struct entry_data

Public Functions

template<>
HPX_NON_COPYABLE(entry_data)
template<>
entry_data()
template<>
hpx::future<void> get_future()
template<>
void set_value()
template<>
bool cancel(std::exception_ptr const &e)

Public Members

template<>
buffer_promise_type promise_
template<>
bool can_be_deleted_
template<>
bool value_set_
template<>
struct erase_on_exit

Public Functions

template<>
erase_on_exit(buffer_map_type &buffer_map, iterator it)
template<>
~erase_on_exit()

Public Members

template<>
buffer_map_type &buffer_map_
template<>
iterator it_