|
![]() |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.ontopia.utils.CachedGrabber
public class CachedGrabber
INTERNAL: Grabber that maintains a cache of previously grabbed objects. It works with any implementation of GrabberIF.
The cache is first checked to see if a grabbed version already exists. Otherwise the object is grabbed and the cache is updated. If the underlying grabber is modified or replaced, the cache is not refreshed automatically. This has to be done explicitly.
Constructor Summary | |
---|---|
CachedGrabber(GrabberIF grabber)
|
Method Summary | |
---|---|
GrabberIF |
getGrabber()
Gets the grabber that is being cached. |
java.lang.Object |
grab(java.lang.Object object)
Returns an object that is somehow extracted from the given object. |
void |
refresh()
Refreshes the cache. |
void |
setGrabber(GrabberIF grabber)
Sets the grabber that is to be cached. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CachedGrabber(GrabberIF grabber)
Method Detail |
---|
public GrabberIF getGrabber()
public void setGrabber(GrabberIF grabber)
public java.lang.Object grab(java.lang.Object object)
GrabberIF
grab
in interface GrabberIF
public void refresh()
CachedIF
refresh
in interface CachedIF
|
![]() |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |