com.bea.util
Class ObjectPool
java.lang.Object
|
+--com.bea.util.ObjectPool
- public abstract class ObjectPool
- extends java.lang.Object
A very, very simple object pool base class that assumes clients will check
objects back in.
- Author:
- Copyright © 2000, 2001 BEA Systems, Inc. All Rights Reserved.
Method Summary
|
void |
checkIn(java.lang.Object obj)
A method for checking objects back into the pool...bad clients don't
check objects back in, so bad clients get bad performance. |
java.lang.Object |
checkOut()
|
protected abstract java.lang.Object |
create()
|
protected abstract void |
expire(java.lang.Object obj)
A method the pool invokes before the object is discarded from the pool. |
protected abstract boolean |
validate(java.lang.Object obj)
|
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
ObjectPool
public ObjectPool()
create
protected abstract java.lang.Object create()
throws java.lang.Exception
- Returns:
- an instance of a pooled object.
- Throws:
- java.lang.Exception - if an error occurs that prevents the pooled object
from being created.
validate
protected abstract boolean validate(java.lang.Object obj)
- Returns:
- true if the pooled object is still valid, i.e. can be reused
expire
protected abstract void expire(java.lang.Object obj)
- A method the pool invokes before the object is discarded from the pool.
checkOut
public final java.lang.Object checkOut()
throws java.lang.Exception
- Returns:
- an object from the pool.
- Throws:
- java.lang.Exception - if an error occurs retrieving the object
checkIn
public final void checkIn(java.lang.Object obj)
- A method for checking objects back into the pool...bad clients don't
check objects back in, so bad clients get bad performance.
WebLogic Integration (WLI)