org.hibernate.cache
public static final class ReadWriteCache.Item extends java.lang.Object implements java.io.Serializable, ReadWriteCache.Lockable
ReadWriteCache
,
Serialized FormConstructor and Description |
---|
ReadWriteCache.Item(java.lang.Object value,
java.lang.Object version,
long currentTimestamp) |
Modifier and Type | Method and Description |
---|---|
long |
getFreshTimestamp()
The timestamp on the cached data
|
java.lang.Object |
getValue()
The actual cached data
|
boolean |
isGettable(long txTimestamp)
Is this item visible to the timestamped
transaction?
|
boolean |
isLock()
Not a lock!
|
boolean |
isPuttable(long txTimestamp,
java.lang.Object newVersion,
java.util.Comparator comparator)
Don't overwite already cached items
|
ReadWriteCache.Lock |
lock(long timeout,
int id)
Lock the item
|
java.lang.String |
toString() |
public ReadWriteCache.Item(java.lang.Object value, java.lang.Object version, long currentTimestamp)
public long getFreshTimestamp()
public java.lang.Object getValue()
public ReadWriteCache.Lock lock(long timeout, int id)
lock
in interface ReadWriteCache.Lockable
public boolean isLock()
isLock
in interface ReadWriteCache.Lockable
public boolean isGettable(long txTimestamp)
isGettable
in interface ReadWriteCache.Lockable
public boolean isPuttable(long txTimestamp, java.lang.Object newVersion, java.util.Comparator comparator)
isPuttable
in interface ReadWriteCache.Lockable
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2014. All Rights Reserved.