hpx::any, hpx::make_any#

Defined in header hpx/any.hpp.

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

template<typename IArch, typename OArch, typename Char>
class hpx::util::basic_any<IArch, OArch, Char, std::true_type>#

Public Functions

inline constexpr basic_any() noexcept#
inline basic_any(basic_any const &x)#
inline basic_any(basic_any &&x) noexcept#
template<typename T, typename Enable = std::enable_if_t<!std::is_same_v<basic_any, std::decay_t<T>>>>
inline basic_any(T &&x, std::enable_if_t<std::is_copy_constructible_v<std::decay_t<T>>>* = nullptr)#
template<typename T, typename ...Ts, typename Enable = std::enable_if_t<std::is_constructible_v<std::decay_t<T>, Ts...> && std::is_copy_constructible_v<std::decay_t<T>>>>
inline explicit basic_any(std::in_place_type_t<T>, Ts&&... ts)#
template<typename T, typename U, typename ...Ts, typename Enable = std::enable_if<std::is_constructible_v<std::decay_t<T>, Ts...> && std::is_copy_constructible_v<std::decay_t<T>>>>
inline explicit basic_any(std::in_place_type_t<T>, std::initializer_list<U> il, Ts&&... ts)#
inline ~basic_any()#
inline basic_any &operator=(basic_any const &x)#
inline basic_any &operator=(basic_any &&rhs) noexcept#
template<typename T, typename Enable = std::enable_if<!std::is_same_v<basic_any, std::decay_t<T>> && std::is_copy_constructible_v<std::decay_t<T>>>>
inline basic_any &operator=(T &&rhs)#
inline basic_any &swap(basic_any &x) noexcept#
inline std::type_info const &type() const#
template<typename T>
inline T const &cast() const#
inline bool has_value() const noexcept#
inline void reset()#
inline bool equal_to(basic_any const &rhs) const noexcept#

Private Functions

inline basic_any &assign(basic_any const &x)#
inline void load(IArch &ar, unsigned const version)#
inline void save(OArch &ar, unsigned const version) const#

Private Members

detail::any::fxn_ptr_table<IArch, OArch, Char, std::true_type> *table#
void *object#

Private Static Functions

template<typename T, typename ...Ts>
static inline void new_object(void *&object, std::true_type, Ts&&... ts)#
template<typename T, typename ...Ts>
static inline void new_object(void *&object, std::false_type, Ts&&... ts)#

Friends

friend class hpx::serialization::access
namespace hpx

Top level HPX namespace.

Typedefs

using any = util::basic_any<serialization::input_archive, serialization::output_archive, char, std::true_type>#

Functions

template<typename T, typename Char>
util::basic_any<serialization::input_archive, serialization::output_archive, Char> make_any(T &&t)#

Constructs an any object containing an object of type T, passing the provided arguments to T’s constructor. Equivalent to:

return std::any(std::in_place_type<T>, std::forward<Args>(args)...);

namespace util

Typedefs

using wany = basic_any<serialization::input_archive, serialization::output_archive, wchar_t, std::true_type>#

Functions

template<typename T, typename Char, typename ...Ts>
basic_any<serialization::input_archive, serialization::output_archive, Char> make_any(Ts&&... ts)#
template<typename T, typename Char, typename U, typename ...Ts>
basic_any<serialization::input_archive, serialization::output_archive, Char> make_any(std::initializer_list<U> il, Ts&&... ts)#
template<typename IArch, typename OArch, typename Char> true_type >

Public Functions

inline constexpr basic_any() noexcept
inline basic_any(basic_any const &x)
inline basic_any(basic_any &&x) noexcept
template<typename T, typename Enable = std::enable_if_t<!std::is_same_v<basic_any, std::decay_t<T>>>>
inline basic_any(T &&x, std::enable_if_t<std::is_copy_constructible_v<std::decay_t<T>>>* = nullptr)
template<typename T, typename ...Ts, typename Enable = std::enable_if_t<std::is_constructible_v<std::decay_t<T>, Ts...> && std::is_copy_constructible_v<std::decay_t<T>>>>
inline explicit basic_any(std::in_place_type_t<T>, Ts&&... ts)
template<typename T, typename U, typename ...Ts, typename Enable = std::enable_if<std::is_constructible_v<std::decay_t<T>, Ts...> && std::is_copy_constructible_v<std::decay_t<T>>>>
inline explicit basic_any(std::in_place_type_t<T>, std::initializer_list<U> il, Ts&&... ts)#
inline ~basic_any()
inline basic_any &operator=(basic_any const &x)
inline basic_any &operator=(basic_any &&rhs) noexcept
template<typename T, typename Enable = std::enable_if<!std::is_same_v<basic_any, std::decay_t<T>> && std::is_copy_constructible_v<std::decay_t<T>>>>
inline basic_any &operator=(T &&rhs)#
inline basic_any &swap(basic_any &x) noexcept
inline std::type_info const &type() const
template<typename T>
inline T const &cast() const
inline bool has_value() const noexcept
inline void reset()
inline bool equal_to(basic_any const &rhs) const noexcept#

Private Functions

inline basic_any &assign(basic_any const &x)
inline void load(IArch &ar, unsigned const version)#
inline void save(OArch &ar, unsigned const version) const#

Private Members

detail::any::fxn_ptr_table<IArch, OArch, Char, std::true_type> *table
void *object

Private Static Functions

template<typename T, typename ...Ts>
static inline void new_object(void *&object, std::true_type, Ts&&... ts)
template<typename T, typename ...Ts>
static inline void new_object(void *&object, std::false_type, Ts&&... ts)

Friends

friend class hpx::serialization::access
struct hash_any#

Public Functions

template<typename Char>
std::size_t operator()(basic_any<serialization::input_archive, serialization::output_archive, Char, std::true_type> const &elem) const#