public class InternalEntryFactoryImpl extends Object implements InternalEntryFactory
| Constructor and Description |
|---|
InternalEntryFactoryImpl() |
| Modifier and Type | Method and Description |
|---|---|
InternalCacheEntry |
create(CacheEntry cacheEntry)
Creates a new
InternalCacheEntry instance based on the key, value, version and timestamp/lifespan
information reflected in the CacheEntry instance passed in. |
InternalCacheEntry |
create(Object key,
Object value,
EntryVersion version,
long created,
long lifespan,
long lastUsed,
long maxIdle)
Creates a new
InternalCacheEntry instance |
InternalCacheEntry |
create(Object key,
Object value,
InternalCacheEntry cacheEntry)
Creates a new
InternalCacheEntry instance based on the version and timestamp/lifespan
information reflected in the CacheEntry instance passed in. |
InternalCacheEntry |
create(Object key,
Object value,
Metadata metadata)
Creates a new
InternalCacheEntry instance |
InternalCacheEntry |
create(Object key,
Object value,
Metadata metadata,
long lifespan,
long maxIdle)
Creates a new
InternalCacheEntry instance |
InternalCacheEntry |
create(Object key,
Object value,
Metadata metadata,
long created,
long lifespan,
long lastUsed,
long maxIdle)
Creates a new
InternalCacheEntry instance |
InternalCacheValue |
createValue(CacheEntry cacheEntry)
Creates an
InternalCacheValue based on the InternalCacheEntry passed in. |
void |
injectTimeService(TimeService timeService) |
InternalCacheEntry |
update(InternalCacheEntry ice,
Metadata metadata)
TODO: Adjust javadoc
Updates an existing
InternalCacheEntry with new metadata. |
public void injectTimeService(TimeService timeService)
public InternalCacheEntry create(Object key, Object value, Metadata metadata)
InternalEntryFactoryInternalCacheEntry instancecreate in interface InternalEntryFactorykey - key to usevalue - value to usemetadata - metadata for entrypublic InternalCacheEntry create(CacheEntry cacheEntry)
InternalEntryFactoryInternalCacheEntry instance based on the key, value, version and timestamp/lifespan
information reflected in the CacheEntry instance passed in.create in interface InternalEntryFactorycacheEntry - cache entry to copypublic InternalCacheEntry create(Object key, Object value, InternalCacheEntry cacheEntry)
InternalEntryFactoryInternalCacheEntry instance based on the version and timestamp/lifespan
information reflected in the CacheEntry instance passed in. Key and value are both passed in
explicitly.create in interface InternalEntryFactorykey - key to usevalue - value to usecacheEntry - cache entry to retrieve version and timestamp/lifespan information frompublic InternalCacheEntry create(Object key, Object value, EntryVersion version, long created, long lifespan, long lastUsed, long maxIdle)
InternalEntryFactoryInternalCacheEntry instancecreate in interface InternalEntryFactorykey - key to usevalue - value to useversion - version to usecreated - creation timestamp to uselifespan - lifespan to uselastUsed - lastUsed timestamp to usemaxIdle - maxIdle to usepublic InternalCacheEntry create(Object key, Object value, Metadata metadata, long created, long lifespan, long lastUsed, long maxIdle)
InternalEntryFactoryInternalCacheEntry instancecreate in interface InternalEntryFactorykey - key to usevalue - value to usemetadata - metadata for entrycreated - creation timestamp to uselifespan - lifespan to uselastUsed - lastUsed timestamp to usemaxIdle - maxIdle to usepublic InternalCacheValue createValue(CacheEntry cacheEntry)
InternalEntryFactoryInternalCacheValue based on the InternalCacheEntry passed in.createValue in interface InternalEntryFactorycacheEntry - to use to generate a InternalCacheValueInternalCacheValuepublic InternalCacheEntry create(Object key, Object value, Metadata metadata, long lifespan, long maxIdle)
InternalEntryFactoryInternalCacheEntry instancecreate in interface InternalEntryFactorykey - key to usevalue - value to usemetadata - metadata for entrylifespan - lifespan to usemaxIdle - maxIdle to usepublic InternalCacheEntry update(InternalCacheEntry ice, Metadata metadata)
InternalEntryFactoryInternalCacheEntry with new metadata. This may result in a new
InternalCacheEntry instance being created, as a different InternalCacheEntry implementation
may be more appropriate to suit the new metadata values. As such, one should consider the InternalCacheEntry
passed in as a parameter as passed by value and not by reference.update in interface InternalEntryFactoryice - original internal cache entrymetadata - new metadataCopyright © 2014 JBoss, a division of Red Hat. All rights reserved.