Deprecated
as a consequence of Cache being deprecated. See corresponding docs for further information.
The optimisitic locking capabilities are only utilized for the entity cache regions.
Unlike the methods on the Cache interface, all the methods
here will only ever be called from access scenarios where versioned
data is actually a possiblity (i.e., entity data). Be sure to consult
with OptimisticCacheSource#isVersioned() to determine whether
versioning is actually in effect.
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public void | writeInsert(Object
The cache key. key, Object The data to be cached. value, Object The entity's version; or null if not versioned. currentVersion)Called during |
| public void | writeLoad(Object
The cache key. key, Object The data to be cached. value, Object The entity's version; or null if not versioned. currentVersion)Called during |
| public void | writeUpdate(Object
The cache key. key, Object The data to be cached. value, Object The entity's current version currentVersion, Object The entity's previous version (before the update);
or null if not versioned. previousVersion)Called during |
| setSource | back to summary |
|---|---|
| public void setSource(OptimisticCacheSource source) Indicates the "source" of the cached data. Currently this will
only ever represent an Made available to the cache so that it can access certain information about versioning strategy.
| |
| writeInsert | back to summary |
|---|---|
| public void writeInsert(Object key, Object value, Object currentVersion) Called during | |
| writeLoad | back to summary |
|---|---|
| public void writeLoad(Object key, Object value, Object currentVersion) Called during | |
| writeUpdate | back to summary |
|---|---|
| public void writeUpdate(Object key, Object value, Object currentVersion, Object previousVersion) Called during | |