Construct a new representation that embeds a TYPE object.

Synopsis

Declared in <bdlcc_sharedobjectpool.h>

template<class CREATOR>
SharedObjectPool_Rep(
    CREATOR* objectCreator,
    bslalg::ConstructorProxy<RESETTER> const& objectResetter,
    PoolType* pool,
    bslma::Allocator* basicAllocator);

Description

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

Parameters

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

Created with MrDocs