[#BloombergLP-bsltf-StdAllocatorAdaptor] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bsltf.adoc[bsltf]::StdAllocatorAdaptor :relfileprefix: ../../ :mrdocs: Provide a facade allocator that propagates adapted allocator state. == Synopsis Declared in `<bsltf_stdallocatoradaptor.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class ALLOCATOR> class StdAllocatorAdaptor : public ALLOCATOR ---- == Description This class template provides the facade of an allocator but mostly delegates operations to the allocator object (of template parameter type) it adapts, except that it enables the propagation of the (stateful) allocator object to constructed elements, if appropriate. == Base Classes [cols="1,4"] |=== | Name| Description | `ALLOCATOR` | |=== == Types [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bsltf/StdAllocatorAdaptor/rebind.adoc[`rebind`] | Provide a namespace for a rebound allocator adaptor type. |=== == Type Aliases [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bsltf/StdAllocatorAdaptor/const_pointer.adoc[`const_pointer`] | Alias for `ALLOCATOR::const_pointer`. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/const_reference.adoc[`const_reference`] | Alias for `ALLOCATOR::const_reference`. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/difference_type.adoc[`difference_type`] | Alias for `ALLOCATOR::difference_type`. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/pointer.adoc[`pointer`] | Alias for `ALLOCATOR::pointer`. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/reference.adoc[`reference`] | Alias for `ALLOCATOR::reference`. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/size_type.adoc[`size_type`] | Alias for `ALLOCATOR::size_type`. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/value_type.adoc[`value_type`] | Alias for `ALLOCATOR::value_type`. |=== == Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bsltf/StdAllocatorAdaptor/2constructor-088.adoc[`StdAllocatorAdaptor`] [.small]#[constructor]# | Create a standard allocator adaptor object for a default‐constructed allocator object of the (template parameter) type `ALLOCATOR`. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/2constructor-00.adoc[`StdAllocatorAdaptor`] [.small]#[constructor]# | Create a copy of the specified `original` allocator adaptor. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/2constructor-089.adoc[`StdAllocatorAdaptor`] [.small]#[constructor]# | Create a copy of the specified `other` allocator adaptor. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/2constructor-07.adoc[`StdAllocatorAdaptor`] [.small]#[constructor]# | Create a standard allocator adaptor object from the null pointer constant. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/2constructor-06.adoc[`StdAllocatorAdaptor`] [.small]#[constructor]# | Create a standard allocator adaptor object for the specified `allocator` of the (template parameter) type `ALLOCATOR`. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/operator_assign.adoc[`operator=`] | Assign to this object the value of the specified `original` object, and return a reference providing modifiable access to this object. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/allocator.adoc[`allocator`] | Return a reference to the non‐modifiable allocator instance associated with this standard allocator adaptor. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/construct.adoc[`construct`] | Construct an object of `ELEMENT_TYPE` at the specified address. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/select_on_container_copy_construction.adoc[`select_on_container_copy_construction`] | Return an adaptor for the allocator selected on container copy. | xref:BloombergLP/bsltf/StdAllocatorAdaptor/2conversion.adoc[`operator BloombergLP::bslmf::NestedTraitDeclaration<StdAllocatorAdaptor, IsStdAllocator>`] | Declare `StdAllocatorAdaptor` as a standard allocator. |=== == Non-Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bsltf/operator_not_eq-092.adoc[`operator!=`] | Return whether two allocator adaptors do not compare equal. | xref:BloombergLP/bsltf/operator_eq-099.adoc[`operator==`] | Return whether two allocator adaptors compare equal. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#