|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Cache<T extends Identifiable>
Cache a stateful object and make sure any life cycle callbacks are called at the appropriate time. A cache is linked to an object factory. How the link is established is left beyond scope.
| Method Summary | |
|---|---|
T |
create(Class<?>[] initTypes,
Object[] initValues)
Create a new object. |
T |
get(Object key)
Get the specified object from cache. |
T |
peek(Object key)
Peek at an object which might be in use. |
void |
release(T obj)
Release the object from use. |
void |
remove(Object key)
Remove the specified object from cache. |
void |
start()
Start the cache. |
void |
stop()
Stop the cache. |
| Method Detail |
|---|
T create(Class<?>[] initTypes,
Object[] initValues)
initTypes - initValues -
T get(Object key)
throws javax.ejb.NoSuchEJBException
key - the identifier of the object
javax.ejb.NoSuchEJBException - if the object does not exist
T peek(Object key)
throws javax.ejb.NoSuchEJBException
key - the identifier of the object
javax.ejb.NoSuchEJBException - if the object does not existvoid release(T obj)
obj - the objectvoid remove(Object key)
key - the identifier of the objectvoid start()
void stop()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||