public final class CacheFactory extends Object
NamedCache
s.Modifier and Type | Method and Description |
---|---|
static NamedCache |
getCache()
Creates a
NamedCache using the default application id. |
static NamedCache |
getCache(com.scaleoutsoftware.soss.client.da.StateServerKey key)
Creates a
NamedCache using the application id extracted from the StateServerKey . |
static NamedCache |
getCache(com.scaleoutsoftware.soss.client.da.StateServerKey key,
boolean registerForEvents)
Deprecated.
the event handling will be automatically enabled when the listener is
registered
NamedCache.addListener(NamedCacheObjectExpirationListener) ;
there is no need to explicitly enable them. |
static NamedCache |
getCache(String name)
Creates a
NamedCache using a specified name. |
static NamedCache |
getCache(String name,
boolean registerForEvents)
Deprecated.
the event handling will be automatically enabled when the listener is
registered
NamedCache.addListener(NamedCacheObjectExpirationListener) ;
there is no need to explicitly enable them. |
public static NamedCache getCache() throws NamedCacheException
NamedCache
using the default application id.NamedCache
NamedCacheException
- Thrown if NamedCache
has experienced an internal error.public static NamedCache getCache(String name) throws NamedCacheException
NamedCache
using a specified name.name
- cache nameNamedCache
NamedCacheException
- Thrown if NamedCache
has experienced an internal error.public static NamedCache getCache(com.scaleoutsoftware.soss.client.da.StateServerKey key) throws NamedCacheException
NamedCache
using the application id extracted from the StateServerKey
.key
- StateServerKey
instance. Only the application id is used.NamedCache
NamedCacheException
- Thrown if NamedCache
has experienced an internal error.public static NamedCache getCache(String name, boolean registerForEvents) throws NamedCacheException
NamedCache.addListener(NamedCacheObjectExpirationListener)
;
there is no need to explicitly enable them.NamedCache
using a specified name.name
- cache nameregisterForEvents
- indicates if this cache should be registered for expiration eventsNamedCache
NamedCacheException
- Thrown if NamedCache
has experienced an internal error.public static NamedCache getCache(com.scaleoutsoftware.soss.client.da.StateServerKey key, boolean registerForEvents) throws NamedCacheException
NamedCache.addListener(NamedCacheObjectExpirationListener)
;
there is no need to explicitly enable them.NamedCache
using the application id extracted from the StateServerKey
.key
- StateServerKey
instance. Only the application id is used.registerForEvents
- indicates if this cache should be registered for expiration eventsNamedCache
NamedCacheException
- Thrown if NamedCache
has experienced an internal error.Copyright (C) 2007-2014 ScaleOut Software, Inc.