BDE 4.14.0 Production release
Loading...
Searching...
No Matches
bslalg::ConstructorProxy_PolymorphicAllocator< TYPE > Class Template Reference

#include <bslalg_constructorproxy.h>

Inheritance diagram for bslalg::ConstructorProxy_PolymorphicAllocator< TYPE >:
bsl::polymorphic_allocator< TYPE >

Public Member Functions

 BSLMF_NESTED_TRAIT_DECLARATION (ConstructorProxy_PolymorphicAllocator, bslma::IsStdAllocator)
 
 BSLMF_NESTED_TRAIT_DECLARATION_IF (ConstructorProxy_PolymorphicAllocator, bslma::UsesBslmaAllocator, false)
 
 ConstructorProxy_PolymorphicAllocator (bsl::memory_resource *r=0)
 
template<class T2 >
 ConstructorProxy_PolymorphicAllocator (const bsl::polymorphic_allocator< T2 > &other)
 
 ConstructorProxy_PolymorphicAllocator (const ConstructorProxy_PolymorphicAllocator &)=default
 
 ~ConstructorProxy_PolymorphicAllocator ()
 
- Public Member Functions inherited from bsl::polymorphic_allocator< TYPE >
 polymorphic_allocator () BSLS_KEYWORD_NOEXCEPT
 
 polymorphic_allocator (memory_resource *r)
 
 polymorphic_allocator (const polymorphic_allocator &original) BSLS_KEYWORD_NOEXCEPT
 
 polymorphic_allocator (const polymorphic_allocator< ANY_TYPE > &original) BSLS_KEYWORD_NOEXCEPT
 
 ~polymorphic_allocator ()=default
 
BSLS_ANNOTATION_NODISCARD TYPE * allocate (std::size_t n)
 
void deallocate (TYPE *p, std::size_t n)
 
void construct (ELEMENT_TYPE *address)
 
void construct (ELEMENT_TYPE *address, ARG1 &argument1, ARGS &&... arguments)
 
void construct (ELEMENT_TYPE *address, BSLS_COMPILERFEATURES_FORWARD_REF(ARG1) argument1, ARGS &&... arguments)
 
void destroy (ELEMENT_TYPE *address)
 
pointer address (reference x) const
 
const_pointer address (const_reference x) const
 
BSLS_KEYWORD_CONSTEXPR size_type max_size () const
 
memory_resourceresource () const
 Return the address of the memory resource supplied on construction.
 
polymorphic_allocator select_on_container_copy_construction () const
 Return a default-constructed polymorphic_allocator.
 

Additional Inherited Members

- Public Types inherited from bsl::polymorphic_allocator< TYPE >
typedef std::size_t size_type
 
typedef std::ptrdiff_t difference_type
 
typedef TYPE * pointer
 
typedef const TYPE * const_pointer
 
typedef TYPE & reference
 
typedef const TYPE & const_reference
 
typedef TYPE value_type
 

Detailed Description

template<class TYPE>
class bslalg::ConstructorProxy_PolymorphicAllocator< TYPE >

Wrapper around bsl::polymorphic_allocator that can tolerate being constructed with a null pointer.

Constructor & Destructor Documentation

◆ ConstructorProxy_PolymorphicAllocator() [1/3]

template<class TYPE >
bslalg::ConstructorProxy_PolymorphicAllocator< TYPE >::ConstructorProxy_PolymorphicAllocator ( bsl::memory_resource r = 0)
inline

Construct from the address of a memory_resource optionally specified by r. If r is null or not specified, construct from the default allocator.

◆ ConstructorProxy_PolymorphicAllocator() [2/3]

template<class TYPE >
template<class T2 >
bslalg::ConstructorProxy_PolymorphicAllocator< TYPE >::ConstructorProxy_PolymorphicAllocator ( const bsl::polymorphic_allocator< T2 > &  other)
inline

Create an allocator using the same memory_resource as the specified other allocator.

◆ ConstructorProxy_PolymorphicAllocator() [3/3]

template<class TYPE >
bslalg::ConstructorProxy_PolymorphicAllocator< TYPE >::ConstructorProxy_PolymorphicAllocator ( const ConstructorProxy_PolymorphicAllocator< TYPE > &  )
default

◆ ~ConstructorProxy_PolymorphicAllocator()

Member Function Documentation

◆ BSLMF_NESTED_TRAIT_DECLARATION()

template<class TYPE >
bslalg::ConstructorProxy_PolymorphicAllocator< TYPE >::BSLMF_NESTED_TRAIT_DECLARATION ( ConstructorProxy_PolymorphicAllocator< TYPE >  ,
bslma::IsStdAllocator   
)

◆ BSLMF_NESTED_TRAIT_DECLARATION_IF()

template<class TYPE >
bslalg::ConstructorProxy_PolymorphicAllocator< TYPE >::BSLMF_NESTED_TRAIT_DECLARATION_IF ( ConstructorProxy_PolymorphicAllocator< TYPE >  ,
bslma::UsesBslmaAllocator  ,
false   
)

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