@Singleton public class PoolLifeCycleRegistry extends Object implements PoolLifeCycle
| Modifier and Type | Field and Description |
|---|---|
protected List<PoolLifeCycle> |
lifeCycleListeners |
| Constructor and Description |
|---|
PoolLifeCycleRegistry() |
| Modifier and Type | Method and Description |
|---|---|
static PoolLifeCycleRegistry |
getRegistry() |
void |
poolCreated(PoolInfo poolInfo)
Invoke poolCreated for all listeners of this pool.
|
void |
poolDestroyed(PoolInfo poolInfo)
Invoke poolDestroyed for all listeners of this pool.
|
void |
registerPoolLifeCycle(PoolLifeCycle listener)
Add a listener to the list of pool life cycle listeners maintained by
this registry for the
poolName. |
void |
unRegisterPoolLifeCycle(PoolLifeCycle listener)
Clear the list of pool lifecycle listeners maintained by the registry.
|
protected List<PoolLifeCycle> lifeCycleListeners
public static PoolLifeCycleRegistry getRegistry()
public void registerPoolLifeCycle(PoolLifeCycle listener)
poolName.poolName - listener - public void unRegisterPoolLifeCycle(PoolLifeCycle listener)
public void poolCreated(PoolInfo poolInfo)
poolCreated in interface PoolLifeCyclepoolInfo - public void poolDestroyed(PoolInfo poolInfo)
poolDestroyed in interface PoolLifeCyclepoolInfo - Copyright © 2017. All rights reserved.