org.jwarp.service.objectpool
Class ObjectPool
java.lang.Object
|
+--org.jwarp.service.objectpool.ObjectPool
- All Implemented Interfaces:
- IObjectPool
- Direct Known Subclasses:
- PersistentObjectPool
- public class ObjectPool
- extends java.lang.Object
- implements IObjectPool
| Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
objectType
protected java.lang.String objectType
objects
protected ICache objects
ObjectPool
public ObjectPool(java.lang.String objectType)
ObjectPool
public ObjectPool(java.lang.String objectType,
ICache cache)
setObjectType
public void setObjectType(java.lang.String objectType)
getObjectType
public java.lang.String getObjectType()
- Returns the class of the pooled objects
- Specified by:
getObjectType in interface IObjectPool
- Returns:
- The objects' class
get
public java.lang.Object get(java.lang.Object key)
throws PersistenceException
- Specified by:
get in interface IObjectPool
put
public void put(IPersistentObject object)
throws PersistenceException
remove
public java.lang.Object remove(java.lang.Object key)
throws PersistenceException
- Specified by:
remove in interface IObjectPool
put
public void put(java.lang.Object key,
java.lang.Object newObject)
throws PersistenceException
- Specified by:
put in interface IObjectPool
getCache
public ICache getCache()