Methods Summary |
---|
public abstract void | destroy()Called when the store is no longer needed. Must clean up and close any
opened resources.
|
protected java.lang.String | getAppId()
return this.appId;
|
protected java.util.Properties | getProperties()
return props;
|
protected void | initialize(java.lang.String appId, java.util.Properties props)
this.appId = appId;
this.props = props;
|
public abstract K | load(java.lang.String id)Load and return the daata for the given id. The store is expected to
return the largest ever version that was saved in the stored using the
save() method. Note that the return value could be null if
Metadata was not accessed for {@link Metadata#getMaxInactiveInterval()}
|
public abstract void | remove(java.lang.String id)Remove the association for the id. After this call, any call to
load(id) must return null
|
public abstract int | removeExpired()Remove all instances that are idle. The implementation of this method
must use {@link Metadata#getLastAccessTime()} and
{@link Metadata#getMaxInactiveInterval()} to determine if a particular
Metadata is idle or not. A Metadata is considered idle if
(Metadata.getMaxInactiveInterval > 0)
&& ((System.currentTimeMillis() - Metadata.getLastAccessTime()) >=
Metadata.getMaxInactiveInterval())
|
public abstract void | save(java.lang.String id, K value)Save the value whose key is id.
|
public abstract int | size()Get the current size of the store
|
public abstract void | updateLastAccessTime(java.lang.String id, long time, long version)Update the last access time for this id.
|