org.mule.util.pool
Class DefaultLifecycleEnabledObjectPool

java.lang.Object
  extended by org.mule.util.pool.CommonsPoolObjectPool
      extended by org.mule.util.pool.DefaultLifecycleEnabledObjectPool
All Implemented Interfaces:
Disposable, Initialisable, Startable, Stoppable, LifecyleEnabledObjectPool, ObjectPool

public class DefaultLifecycleEnabledObjectPool
extends CommonsPoolObjectPool
implements LifecyleEnabledObjectPool

A LifecyleEnabledObjectPool implementation for pooling LifecycleAdapter instances for implementations of JavaComponent that require LifecycleAdapter pooling such as PooledJavaComponent.

See Also:
PooledJavaComponent

Field Summary
protected static Log logger
          logger used by this class
protected  edu.emory.mathcs.backport.java.util.concurrent.atomic.AtomicBoolean started
           
 
Fields inherited from class org.mule.util.pool.CommonsPoolObjectPool
objectFactory, pool, poolingProfile
 
Fields inherited from interface org.mule.api.lifecycle.Initialisable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Disposable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Startable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Stoppable
PHASE_NAME
 
Constructor Summary
DefaultLifecycleEnabledObjectPool(ObjectFactory objectFactory, PoolingProfile poolingProfile)
           
 
Method Summary
protected  PoolableObjectFactory getPooledObjectFactory()
          Template method to be overridden by implementations that do more than just invoke objectFactory
 void start()
           
 void stop()
           
 
Methods inherited from class org.mule.util.pool.CommonsPoolObjectPool
applyInitialisationPolicy, borrowObject, clear, close, dispose, getMaxActive, getNumActive, getObjectFactory, initialise, returnObject, setObjectFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.mule.util.pool.ObjectPool
borrowObject, clear, close, getMaxActive, getNumActive, getObjectFactory, returnObject, setObjectFactory
 
Methods inherited from interface org.mule.api.lifecycle.Initialisable
initialise
 
Methods inherited from interface org.mule.api.lifecycle.Disposable
dispose
 

Field Detail

logger

protected static final Log logger
logger used by this class


started

protected edu.emory.mathcs.backport.java.util.concurrent.atomic.AtomicBoolean started
Constructor Detail

DefaultLifecycleEnabledObjectPool

public DefaultLifecycleEnabledObjectPool(ObjectFactory objectFactory,
                                         PoolingProfile poolingProfile)
Parameters:
objectFactory - The object factory that should be used to create new LifecycleAdapter instance for the pool
poolingProfile - The pooling progile ot be used to configure pool
Method Detail

getPooledObjectFactory

protected PoolableObjectFactory getPooledObjectFactory()
Description copied from class: CommonsPoolObjectPool
Template method to be overridden by implementations that do more than just invoke objectFactory

Overrides:
getPooledObjectFactory in class CommonsPoolObjectPool
Returns:

start

public void start()
           throws MuleException
Specified by:
start in interface Startable
Throws:
MuleException

stop

public void stop()
          throws MuleException
Specified by:
stop in interface Stoppable
Throws:
MuleException


Copyright © 2003-2009 MuleSource, Inc.. All Rights Reserved.