public abstract class TestCacheCallback extends java.lang.Object implements CacheCallback
wasInvoked()
Modifier and Type | Field and Description |
---|---|
protected java.lang.Throwable |
callbackError |
Constructor and Description |
---|
TestCacheCallback() |
Modifier and Type | Method and Description |
---|---|
void |
close()
Called when the region containing this callback is closed or destroyed, when the cache is
closed, or when a callback is removed from a region using an
AttributesMutator . |
void |
close2()
This method will do nothing.
|
boolean |
isClosed() |
boolean |
waitForInvocation(int timeoutMs)
Waits up to timeoutMs milliseconds for the listener to be invoked.
|
boolean |
waitForInvocation(int timeoutMs,
long interval) |
boolean |
wasInvoked()
Returns whether or not one of this
CacheListener methods was invoked. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
init, initialize
public boolean wasInvoked()
CacheListener
methods was invoked. Before
returning, the invoked
flag is cleared.public boolean waitForInvocation(int timeoutMs)
public boolean waitForInvocation(int timeoutMs, long interval)
public boolean isClosed()
public void close()
CacheCallback
AttributesMutator
.
Implementations should cleanup any external resources such as database connections. Any runtime exceptions this method throws will be logged.
It is possible for this method to be called multiple times on a single callback instance, so implementations must be tolerant of this.
close
in interface CacheCallback
RegionService.close()
,
Region.close()
,
Region.localDestroyRegion()
,
Region.destroyRegion()
,
AttributesMutator
public void close2()