BloombergLP::bdlb::Variant12::Variant12

Constructors

Synopses

Declared in <bdlb_variant.h>

Create a variant object in the unset state that uses the currently installed default allocator to supply memory.

Variant12();
» more...

Create a variant by moving from original.

Variant12(bslmf::MovableRef<Variant12> original);
» more...

Create a variant from valueOrAllocator.

template<class TYPE_OR_ALLOCATOR>
explicit
Variant12(TYPE_OR_ALLOCATOR const& valueOrAllocator);
» more...

Create a variant by moving from the specified value.

template<class TYPE>
explicit
Variant12(TYPE&& value)
requires !bsl::is_same<
                      SelfType,
                      typename bsl::remove_const<
                      typename bsl::remove_reference<TYPE>::type>::type>::value
                  &&
                  !bsl::is_convertible<TYPE, bslma::Allocator *>::value;
» more...

Create a variant holding value using basicAllocator.

template<class TYPE>
Variant12(TYPE&& value)
requires !bsl::is_same<
                     SelfType,
                     typename bsl::remove_const<
                     typename bsl::remove_reference<TYPE>::type>::type>::value;
» more...

Create a variant from original using basicAllocator.

Variant12(
    bslmf::MovableRef<Variant12> original,
    bslma::Allocator* basicAllocator);
» more...

Create a variant with the type and value of original.

Variant12(
    Variant12 const& original,
    bslma::Allocator* basicAllocator = 0);
» more...

Create a variant holding value using basicAllocator.

template<class TYPE>
Variant12(
    TYPE const& value,
    bslma::Allocator* basicAllocator);
» more...

Parameters

NameDescription
originalsource variant to copy or move from
valueOrAllocatorheld value, or allocator if convertible to bslma::Allocator *
valuevalue assigned to or stored in this variant
basicAllocatorallocator used to supply memory