public class DefaultCacheEntryView extends Object implements CacheEntryView<Data,Data>, IdentifiedDataSerializable
CacheEntryView
.Constructor and Description |
---|
DefaultCacheEntryView() |
DefaultCacheEntryView(Data key,
Data value,
long creationTime,
long expirationTime,
long lastAccessTime,
long accessHit) |
Modifier and Type | Method and Description |
---|---|
long |
getAccessHit()
Gets the count of how many time this cache entry has been accessed.
|
long |
getCreationTime()
Gets the creation time of this
EvictableEntryView in milliseconds. |
long |
getExpirationTime()
Gets the expiration time in milliseconds of the cache entry.
|
int |
getFactoryId()
Returns DataSerializableFactory factory ID for this class.
|
int |
getId()
Returns type identifier for this class.
|
Data |
getKey()
Gets the key of the cache entry.
|
long |
getLastAccessTime()
Gets the last access time in milliseconds of the cache entry.
|
Data |
getValue()
Gets the value of the cache entry.
|
void |
readData(ObjectDataInput in)
Reads fields from the input stream
|
void |
writeData(ObjectDataOutput out)
Writes object fields to output stream
|
public Data getKey()
CacheEntryView
getKey
in interface CacheEntryView<Data,Data>
getKey
in interface EvictableEntryView<Data,Data>
public Data getValue()
CacheEntryView
getValue
in interface CacheEntryView<Data,Data>
getValue
in interface EvictableEntryView<Data,Data>
public long getCreationTime()
EvictableEntryView
EvictableEntryView
in milliseconds.getCreationTime
in interface EvictableEntryView<Data,Data>
EvictableEntryView
in millisecondspublic long getExpirationTime()
CacheEntryView
getExpirationTime
in interface CacheEntryView<Data,Data>
public long getLastAccessTime()
CacheEntryView
getLastAccessTime
in interface CacheEntryView<Data,Data>
getLastAccessTime
in interface EvictableEntryView<Data,Data>
public long getAccessHit()
CacheEntryView
getAccessHit
in interface CacheEntryView<Data,Data>
getAccessHit
in interface EvictableEntryView<Data,Data>
public void writeData(ObjectDataOutput out) throws IOException
DataSerializable
writeData
in interface DataSerializable
out
- outputIOException
public void readData(ObjectDataInput in) throws IOException
DataSerializable
readData
in interface DataSerializable
in
- inputIOException
public int getFactoryId()
IdentifiedDataSerializable
getFactoryId
in interface IdentifiedDataSerializable
public int getId()
IdentifiedDataSerializable
getId
in interface IdentifiedDataSerializable
Copyright © 2017 Hazelcast, Inc.. All Rights Reserved.