Class DistributedExoCache<K extends Serializable,V>
java.lang.Object
org.exoplatform.services.cache.impl.infinispan.distributed.DistributedExoCache<K,V>
- All Implemented Interfaces:
org.exoplatform.services.cache.ExoCache<K,V>
public class DistributedExoCache<K extends Serializable,V>
extends Object
implements org.exoplatform.services.cache.ExoCache<K,V>
- Version:
- $Id$
- Author:
- Nicolas Filotto
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassstatic classstatic classstatic classstatic classstatic classstatic classstatic classstatic classstatic class -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final org.infinispan.AdvancedCache<DistributedExoCache.CacheKey<K>,V> static final String -
Constructor Summary
ConstructorsConstructorDescriptionDistributedExoCache(org.exoplatform.container.ExoContainerContext ctx, org.exoplatform.services.cache.ExoCacheConfig config, org.infinispan.Cache<K, V> cache) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCacheListener(org.exoplatform.services.cache.CacheListener<? super K, ? super V> listener) voidget(Serializable name) intintintgetLabel()longlongintgetName()longbooleanbooleanbooleanvoidvoidvoidvoidprotected voidOnly puts the data into the cache nothing moreremove(Serializable name) voidvoidsetDistributed(boolean distributed) voidvoidsetLiveTime(long period) voidsetLogEnabled(boolean logEnabled) voidsetMaxSize(int max) voidvoidsetReplicated(boolean replicated) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.exoplatform.services.cache.ExoCache
onExpire, onGet, onPutLocal, onRemove, putAsyncMap, putLocal, removeLocal
-
Field Details
-
CACHE_NAME
- See Also:
-
cache
protected final org.infinispan.AdvancedCache<DistributedExoCache.CacheKey<K extends Serializable>,V> cache
-
-
Constructor Details
-
DistributedExoCache
-
-
Method Details
-
addCacheListener
public void addCacheListener(org.exoplatform.services.cache.CacheListener<? super K, ? super V> listener) - Specified by:
addCacheListenerin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
clearCache
public void clearCache()- Specified by:
clearCachein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
get
- Specified by:
getin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getCacheHit
public int getCacheHit()- Specified by:
getCacheHitin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getCacheMiss
public int getCacheMiss()- Specified by:
getCacheMissin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getCacheSize
public int getCacheSize()- Specified by:
getCacheSizein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getCachedObjects
- Specified by:
getCachedObjectsin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getLabel
- Specified by:
getLabelin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getName
- Specified by:
getNamein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
isDistributed
public boolean isDistributed() -
isLogEnabled
public boolean isLogEnabled()- Specified by:
isLogEnabledin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
isReplicated
public boolean isReplicated() -
put
- Specified by:
putin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V> - Throws:
IllegalArgumentException
-
putOnly
Only puts the data into the cache nothing more -
putMap
- Specified by:
putMapin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V> - Throws:
IllegalArgumentException
-
remove
- Specified by:
removein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V> - Throws:
IllegalArgumentException
-
removeCachedObjects
- Specified by:
removeCachedObjectsin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
select
public void select(org.exoplatform.services.cache.CachedObjectSelector<? super K, ? super V> selector) throws Exception- Specified by:
selectin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V> - Throws:
Exception
-
setDistributed
public void setDistributed(boolean distributed) -
setLabel
- Specified by:
setLabelin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
setLogEnabled
public void setLogEnabled(boolean logEnabled) - Specified by:
setLogEnabledin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
setName
- Specified by:
setNamein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
setReplicated
public void setReplicated(boolean replicated) -
onPut
- Specified by:
onPutin interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
onClearCache
public void onClearCache()- Specified by:
onClearCachein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
setMaxSize
public void setMaxSize(int max) - Specified by:
setMaxSizein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
setLiveTime
public void setLiveTime(long period) - Specified by:
setLiveTimein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getMaxSize
public int getMaxSize()- Specified by:
getMaxSizein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getLiveTime
public long getLiveTime()- Specified by:
getLiveTimein interfaceorg.exoplatform.services.cache.ExoCache<K extends Serializable,V>
-
getMaxIdle
public long getMaxIdle() -
getWakeUpInterval
public long getWakeUpInterval()
-