45 typedef typename std::vector<T*>::iterator It;
86 std::copy(instances.begin(), instances.end(),
A pool of resuable instances.
void addFreeInstances(const std::vector< T * > instances)
Adds some free, reusable instances.
bool myDeleteOnQuit
Information whether the stored instances shall be deleted.
void addFreeInstance(T *instance)
Adds a free, reusable instance.
~InstancePool()
Destructor.
std::vector< T * > myFreeInstances
List of reusable instances.
T * getFreeInstance()
Returns a free instance or 0 if no such exists.
InstancePool(bool deleteOnQuit)
Constructor.