Component‐private class template implementing bsl::optional.
Synopsis
Declared in <bslstl_optional.h>
template<
class t_TYPE,
bool t_USES_BSLMA_ALLOC = BloombergLP::bslma::UsesBslmaAllocator<t_TYPE>::value>
class Optional_Base;
Description
This component‐private class template implements the functionality of bsl::optional. The primary template is instantiated when TYPE is allocator‐aware, and holds the allocator that is used to create the stored object.
Type Aliases
Name |
Description |
This |
|
Alias for the managed object type of this optional. |
Member Functions
Name |
Description |
Assignment operators |
|
Destroy any contained value and construct a new one in place. |
|
Return allocator used for construction of |
|
Return |
|
Dereference operators |
|
Member access operators |
|
Reset this object to the default constructed state (i.e., to a disengaged state). |
|
Exchange the values of two optionals. |
|
|
|
Return the contained value, or a converted fallback if disengaged. |
|
Nested trait declaration for |
|
Nested trait declaration for |
|
|
Nested trait declaration for |
|
Nested trait declaration for |
Return |
Protected Type Aliases
Name |
Description |
This |
Protected Member Functions
Name |
Description |
|
Constructors |
Assign or emplace a value into this optional. |
|
Return a reference to the contained value without checking engagement. |
Specializations
Name |
Description |
Specialization of |