public static interface AbstractReadWriteAccess.Lockable
Interface type implemented by all wrapper objects in the cache.
Modifier and Type | Method and Description |
---|---|
Object |
getValue()
Returns the enclosed value.
|
boolean |
isReadable(long txTimestamp)
Returns <code>true</code> if the enclosed value can be read by a transaction started at the given time.
|
boolean |
isUnlockable(SoftLock lock)
Returns <code>true</code> if the given lock can be unlocked using the given SoftLock instance as a handle.
|
boolean |
isWriteable(long txTimestamp,
Object version,
Comparator versionComparator)
Returns <code>true</code> if the enclosed value can be replaced with one of the given version by a
transaction started at the given time.
|
AbstractReadWriteAccess.SoftLockImpl |
lock(long timeout,
UUID uuid,
long lockId)
Locks this entry, stamping it with the UUID and lockId given, with the lock timeout occuring at the specified
time.
|
boolean isReadable(long txTimestamp)
Returns <code>true</code> if the enclosed value can be read by a transaction started at the given time.
boolean isWriteable(long txTimestamp, Object version, Comparator versionComparator)
Returns <code>true</code> if the enclosed value can be replaced with one of the given version by a transaction started at the given time.
Object getValue()
Returns the enclosed value.
boolean isUnlockable(SoftLock lock)
Returns <code>true</code> if the given lock can be unlocked using the given SoftLock instance as a handle.
AbstractReadWriteAccess.SoftLockImpl lock(long timeout, UUID uuid, long lockId)
Locks this entry, stamping it with the UUID and lockId given, with the lock timeout occuring at the specified time. The returned Lock object can be used to unlock the entry in the future.
Copyright © 2001-2018 Red Hat, Inc. All Rights Reserved.