Class ManagedObjectPoolBuilderImpl
- java.lang.Object
-
- net.officefloor.frame.impl.construct.managedobjectpool.ManagedObjectPoolBuilderImpl
-
- All Implemented Interfaces:
ManagedObjectPoolBuilder
,ManagedObjectPoolConfiguration
public class ManagedObjectPoolBuilderImpl extends java.lang.Object implements ManagedObjectPoolBuilder, ManagedObjectPoolConfiguration
Implements theManagedObjectPoolBuilder
.- Author:
- Daniel Sagenschneider
-
-
Constructor Summary
Constructors Constructor Description ManagedObjectPoolBuilderImpl(ManagedObjectPoolFactory managedObjectPoolFactory)
Instantiate.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addThreadCompletionListener(ThreadCompletionListenerFactory threadCompletionListenerFactory)
Adds aThreadCompletionListener
.ManagedObjectPoolFactory
getManagedObjectPoolFactory()
Obtains theManagedObjectPoolFactory
.ThreadCompletionListenerFactory[]
getThreadCompletionListenerFactories()
Obtains theThreadCompletionListenerFactory
instances.
-
-
-
Constructor Detail
-
ManagedObjectPoolBuilderImpl
public ManagedObjectPoolBuilderImpl(ManagedObjectPoolFactory managedObjectPoolFactory)
Instantiate.- Parameters:
managedObjectPoolFactory
-ManagedObjectPoolFactory
.
-
-
Method Detail
-
addThreadCompletionListener
public void addThreadCompletionListener(ThreadCompletionListenerFactory threadCompletionListenerFactory)
Description copied from interface:ManagedObjectPoolBuilder
Adds a
ThreadCompletionListener
.This allows the
ManagedObjectPool
to cache objects toThreadLocal
instances and be notified when theThread
is complete to clean up theThreadLocal
state.- Specified by:
addThreadCompletionListener
in interfaceManagedObjectPoolBuilder
- Parameters:
threadCompletionListenerFactory
-ThreadCompletionListenerFactory
.
-
getManagedObjectPoolFactory
public ManagedObjectPoolFactory getManagedObjectPoolFactory()
Description copied from interface:ManagedObjectPoolConfiguration
Obtains theManagedObjectPoolFactory
.- Specified by:
getManagedObjectPoolFactory
in interfaceManagedObjectPoolConfiguration
- Returns:
ManagedObjectPoolFactory
.
-
getThreadCompletionListenerFactories
public ThreadCompletionListenerFactory[] getThreadCompletionListenerFactories()
Description copied from interface:ManagedObjectPoolConfiguration
Obtains theThreadCompletionListenerFactory
instances.- Specified by:
getThreadCompletionListenerFactories
in interfaceManagedObjectPoolConfiguration
- Returns:
ThreadCompletionListenerFactory
instances.
-
-