public class CacheRecordFactory<R extends CacheRecord> extends Object
CacheRecord
.
Key, value and expiryTime are packed into a subclass of
AbstractCacheRecord
depending on the configured inMemoryFormat.
Modifier and Type | Field and Description |
---|---|
protected InMemoryFormat |
inMemoryFormat |
protected SerializationService |
serializationService |
Constructor and Description |
---|
CacheRecordFactory(InMemoryFormat inMemoryFormat,
SerializationService serializationService) |
Modifier and Type | Method and Description |
---|---|
protected CacheRecord |
createCacheDataRecord(Data dataValue,
long creationTime,
long expiryTime) |
protected CacheRecord |
createCacheObjectRecord(Object objectValue,
long creationTime,
long expiryTime) |
static boolean |
isExpiredAt(long expirationTime,
long now)
Determines whether the Cache Entry associated with this value will expire
at the specified time.
|
R |
newRecordWithExpiry(Object value,
long creationTime,
long expiryTime) |
protected InMemoryFormat inMemoryFormat
protected SerializationService serializationService
public CacheRecordFactory(InMemoryFormat inMemoryFormat, SerializationService serializationService)
protected CacheRecord createCacheDataRecord(Data dataValue, long creationTime, long expiryTime)
protected CacheRecord createCacheObjectRecord(Object objectValue, long creationTime, long expiryTime)
public static boolean isExpiredAt(long expirationTime, long now)
expirationTime
- the expiration timenow
- the time in milliseconds (since the Epoc)Copyright © 2018 Hazelcast, Inc.. All Rights Reserved.