[#BloombergLP-bdlcc-SharedObjectPool_Rep-2constructor]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlcc.adoc[bdlcc]::xref:BloombergLP/bdlcc/SharedObjectPool_Rep.adoc[SharedObjectPool&lowbar;Rep]::SharedObjectPool&lowbar;Rep
:relfileprefix: ../../../
:mrdocs:

Construct a new representation that embeds a `TYPE` object&period;

== Synopsis

Declared in `&lt;bdlcc&lowbar;sharedobjectpool&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class CREATOR&gt;
SharedObjectPool&lowbar;Rep(
    CREATOR* objectCreator,
    xref:BloombergLP/bslalg/ConstructorProxy.adoc[bslalg::ConstructorProxy&lt;RESETTER&gt;] const& objectResetter,
    xref:BloombergLP/bdlcc/SharedObjectPool_Rep.adoc[PoolType]* pool,
    xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* basicAllocator);
----

== Description

Construct a new rep object that, upon release, will invoke the specified `objectResetter` and return itself to the specified `pool`&semi; then invoke `objectCreator` to construct an object of `TYPE` embedded within the new rep object&period; Use the specified `basicAllocator` to supply memory&period; If `basicAllocator` is 0, the currently installed default allocator is used&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *objectCreator*
| creator invoked to construct the embedded object
| *objectResetter*
| resetter invoked when this rep is released
| *pool*
| pool to which this representation is returned
| *basicAllocator*
| allocator used to supply memory
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
