libstdc++
GNU C++ library
Loading...
Searching...
No Matches
std::experimental::fundamentals_v1::any Class Reference

#include "any"

Collaboration diagram for std::experimental::fundamentals_v1::any:
Collaboration graph

Classes

union  _Arg
struct  _Manager_external
struct  _Manager_internal
struct  _Manager_internal< any::_Op >
union  _Storage

Public Member Functions

 any () noexcept
template<typename _ValueType, typename _Tp = _Decay<_ValueType>, typename _Mgr = _Manager<_Tp>, typename enable_if<!is_constructible< _Tp, _ValueType && >::value, bool >::type = false>
 any (_ValueType &&__value)
template<typename _ValueType, typename _Tp = _Decay<_ValueType>, typename _Mgr = _Manager<_Tp>, typename enable_if< is_constructible< _Tp, _ValueType && >::value, bool >::type = true>
 any (_ValueType &&__value)
 any (any &&__other) noexcept
 any (const any &__other)
 ~any ()
void clear () noexcept
bool empty () const noexcept
template<typename _ValueType>
enable_if_t<!is_same< any, decay_t< _ValueType > >::value, any & > operator= (_ValueType &&__rhs)
anyoperator= (any &&__rhs) noexcept
anyoperator= (const any &__rhs)
void swap (any &__rhs) noexcept
const type_infotype () const noexcept

Static Public Member Functions

template<typename _Tp>
static constexpr bool __is_valid_cast ()

Private Types

template<typename _Tp, typename _Decayed = decay_t<_Tp>>
using _Decay = enable_if_t<!is_same<_Decayed, any>::value, _Decayed>
template<typename _Tp, typename _Safe = is_nothrow_move_constructible<_Tp>, bool _Fits = (sizeof(_Tp) <= sizeof(_Storage)) && (alignof(_Tp) <= alignof(_Storage))>
using _Internal = std::integral_constant<bool, _Safe::value && _Fits>
template<typename _Tp>
using _Manager
enum  _Op { _Op_access , _Op_get_type_info , _Op_clone , _Op_destroy , _Op_xfer }

Private Attributes

void(* _M_manager )(_Op, const any *, _Arg *)
_Storage _M_storage

Friends

template<typename _Tp>
enable_if_t< is_object< _Tp >::value, void * > __any_caster (const any *__any)

Detailed Description

A type-safe container of any type.

An any object's state is either empty or it stores a contained object of CopyConstructible type.

Definition at line 94 of file experimental/any.


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