lcos_distributed

The contents of this module can be included with the header hpx/modules/lcos_distributed.hpp. These headers may be used by user-code but are not guaranteed stable (neither header location nor contents). You are using these at your own risk. If you wish to use non-public functionality from a module we strongly suggest only including the module header hpx/modules/lcos_distributed.hpp, not the particular header in which the functionality you would like to use is defined. See Public API for a list of names that are part of the public HPX API.

Header hpx/distributed/channel.hpp

Header hpx/lcos_distributed/channel.hpp

namespace hpx
namespace lcos
template<typename T>
class channel : public components::client_base<channel<T>, lcos::server::channel<T>>
#include <channel.hpp>

Public Types

typedef T value_type

Public Functions

channel()
channel(naming::id_type const &loc)
channel(hpx::future<naming::id_type> &&id)
channel(hpx::shared_future<naming::id_type> &&id)
channel(hpx::shared_future<naming::id_type> const &id)
hpx::future<T> get(launch::async_policy, std::size_t generation = default_generation) const
hpx::future<T> get(std::size_t generation = default_generation) const
T get(launch::sync_policy, std::size_t generation = default_generation, hpx::error_code &ec = hpx::throws) const
T get(launch::sync_policy, hpx::error_code &ec, std::size_t generation = default_generation) const
template<typename U, typename U2 = T>
std::enable_if<!std::is_void<U2>::value, bool>::type set(launch::apply_policy, U val, std::size_t generation = default_generation)
template<typename U, typename U2 = T>
std::enable_if<!std::is_void<U2>::value, hpx::future<void>>::type set(launch::async_policy, U val, std::size_t generation = default_generation)
template<typename U, typename U2 = T>
std::enable_if<!std::is_void<U2>::value>::type set(launch::sync_policy, U val, std::size_t generation = default_generation)
template<typename U, typename U2 = T>
std::enable_if<!std::is_void<U2>::value && !traits::is_launch_policy<U>::value>::type set(U val, std::size_t generation = default_generation)
template<typename U = T>
std::enable_if<std::is_void<U>::value, bool>::type set(launch::apply_policy, std::size_t generation = default_generation)
template<typename U = T>
std::enable_if<std::is_void<U>::value, hpx::future<void>>::type set(launch::async_policy, std::size_t generation = default_generation)
template<typename U = T>
std::enable_if<std::is_void<U>::value>::type set(launch::sync_policy, std::size_t generation = default_generation)
template<typename U = T>
std::enable_if<std::is_void<U>::value>::type set(std::size_t generation = default_generation)
void close(launch::apply_policy, bool force_delete_entries = false)
hpx::future<std::size_t> close(launch::async_policy, bool force_delete_entries = false)
std::size_t close(launch::sync_policy, bool force_delete_entries = false)
std::size_t close(bool force_delete_entries = false)
channel_iterator<T, channel<T>> begin() const
channel_iterator<T, channel<T>> end() const
channel_iterator<T, channel<T>> rbegin() const
channel_iterator<T, channel<T>> rend() const

Private Types

typedef components::client_base<channel<T>, lcos::server::channel<T>> base_type

Private Static Attributes

constexpr std::size_t default_generation = std::size_t(-1)
template<typename T, typename Channel>
class channel_iterator : public hpx::util::iterator_facade<channel_iterator<T, Channel>, T const, std::input_iterator_tag>
#include <channel.hpp>

Public Functions

channel_iterator()
channel_iterator(Channel const &c)

Private Types

typedef hpx::util::iterator_facade<channel_iterator<T, Channel>, T const, std::input_iterator_tag> base_type

Private Functions

std::pair<T, bool> get_checked() const
bool equal(channel_iterator const &rhs) const
void increment()
base_type::reference dereference() const

Private Members

Channel const *channel_
std::pair<T, bool> data_

Friends

friend hpx::lcos::hpx::util::iterator_core_access
template<typename Channel>
class channel_iterator<void, Channel> : public hpx::util::iterator_facade<channel_iterator<void, Channel>, util::unused_type const, std::input_iterator_tag>
#include <channel.hpp>

Public Functions

channel_iterator()
channel_iterator(Channel const &c)

Private Types

typedef hpx::util::iterator_facade<channel_iterator<void, Channel>, util::unused_type const, std::input_iterator_tag> base_type

Private Functions

bool get_checked()
bool equal(channel_iterator const &rhs) const
void increment()
base_type::reference dereference() const

Private Members

Channel const *channel_
bool data_

Friends

friend hpx::lcos::hpx::util::iterator_core_access
template<typename T>
class receive_channel : public components::client_base<receive_channel<T>, lcos::server::channel<T>>
#include <channel.hpp>

Public Types

typedef T value_type

Public Functions

receive_channel()
receive_channel(channel<T> const &c)
receive_channel(hpx::future<naming::id_type> &&id)
receive_channel(hpx::shared_future<naming::id_type> &&id)
receive_channel(hpx::shared_future<naming::id_type> const &id)
hpx::future<T> get(launch::async_policy, std::size_t generation = default_generation) const
hpx::future<T> get(std::size_t generation = default_generation) const
T get(launch::sync_policy, std::size_t generation = default_generation, hpx::error_code &ec = hpx::throws) const
T get(launch::sync_policy, hpx::error_code &ec, std::size_t generation = default_generation) const
channel_iterator<T, channel<T>> begin() const
channel_iterator<T, channel<T>> end() const
channel_iterator<T, channel<T>> rbegin() const
channel_iterator<T, channel<T>> rend() const

Private Types

typedef components::client_base<receive_channel<T>, lcos::server::channel<T>> base_type

Private Static Attributes

constexpr std::size_t default_generation = std::size_t(-1)
template<typename T>
class send_channel : public components::client_base<send_channel<T>, lcos::server::channel<T>>
#include <channel.hpp>

Public Types

typedef T value_type

Public Functions

send_channel()
send_channel(channel<T> const &c)
send_channel(hpx::future<naming::id_type> &&id)
send_channel(hpx::shared_future<naming::id_type> &&id)
send_channel(hpx::shared_future<naming::id_type> const &id)
template<typename U, typename U2 = T>
std::enable_if<!std::is_void<U2>::value, bool>::type set(launch::apply_policy, U val, std::size_t generation = default_generation)
template<typename U, typename U2 = T>
std::enable_if<!std::is_void<U2>::value, hpx::future<void>>::type set(launch::async_policy, U val, std::size_t generation = default_generation)
template<typename U, typename U2 = T>
std::enable_if<!std::is_void<U2>::value>::type set(launch::sync_policy, U val, std::size_t generation = default_generation)
template<typename U, typename U2 = T>
std::enable_if<!std::is_void<U2>::value && !traits::is_launch_policy<U>::value>::type set(U val, std::size_t generation = default_generation)
template<typename U = T>
std::enable_if<std::is_void<U>::value, bool>::type set(launch::apply_policy, std::size_t generation = default_generation)
template<typename U = T>
std::enable_if<std::is_void<U>::value, hpx::future<void>>::type set(launch::async_policy, std::size_t generation = default_generation)
template<typename U = T>
std::enable_if<std::is_void<U>::value>::type set(launch::sync_policy, std::size_t generation = default_generation)
template<typename U = T>
std::enable_if<std::is_void<U>::value>::type set(std::size_t generation = default_generation)
void close(launch::apply_policy, bool force_delete_entries = false)
hpx::future<std::size_t> close(launch::async_policy, bool force_delete_entries = false)
std::size_t close(launch::sync_policy, bool force_delete_entries = false)
std::size_t close(bool force_delete_entries = false)

Private Types

typedef components::client_base<send_channel<T>, lcos::server::channel<T>> base_type

Private Static Attributes

constexpr std::size_t default_generation = std::size_t(-1)

Header hpx/lcos_distributed/server/channel.hpp

Defines

HPX_REGISTER_CHANNEL_DECLARATION(...)
HPX_REGISTER_CHANNEL_DECLARATION_(...)
HPX_REGISTER_CHANNEL_DECLARATION_1(type)
HPX_REGISTER_CHANNEL_DECLARATION_2(type, name)
HPX_REGISTER_CHANNEL(...)
HPX_REGISTER_CHANNEL_(...)
HPX_REGISTER_CHANNEL_1(type)
HPX_REGISTER_CHANNEL_2(type, name)
namespace hpx
namespace lcos
namespace server
template<typename T, typename RemoteType>
class channel : public lcos::base_lco_with_value<T, RemoteType, traits::detail::component_tag>, public components::component_base<channel<T, RemoteType>>
#include <channel.hpp>

Public Types

typedef lcos::base_lco_with_value<T, RemoteType, traits::detail::component_tag> base_type_holder
typedef base_type::wrapping_type wrapping_type

Public Functions

channel()
void set_value(RemoteType &&result)
void set_exception(std::exception_ptr const&)
result_type get_value()
result_type get_value(error_code &ec)
hpx::future<T> get_generation(std::size_t generation)
HPX_DEFINE_COMPONENT_DIRECT_ACTION(channel, get_generation)
void set_generation(RemoteType &&value, std::size_t generation)
HPX_DEFINE_COMPONENT_DIRECT_ACTION(channel, set_generation)
std::size_t close(bool force_delete_entries)
HPX_DEFINE_COMPONENT_ACTION(channel, close)

Public Static Functions

static components::component_type get_component_type()
static void set_component_type(components::component_type type)

Private Types

typedef components::component_base<channel> base_type
typedef std::conditional<std::is_void<T>::value, util::unused_type, T>::type result_type

Private Members

lcos::local::channel<result_type> channel_