public class GroupCreationContext<K extends Serializable,V extends Cacheable<K>,G extends Serializable,M extends SerializationGroupMember<K,V,G>,C extends GroupAwareBackingCache<K,V,G,M>> extends Object
Cacheable
s that are being created as members of a
SerializationGroup
. Implementation is based on a ThreadLocal
.Modifier and Type | Method and Description |
---|---|
static void |
clearGroupCreationContext()
Clears the association of any GroupCreationContext with the current thread.
|
List<Map.Entry<V,C>> |
getEntries()
Gets the list of cache items and associated caches that currently comprise the group.
|
static <K extends Serializable,V extends Cacheable<K>,G extends Serializable,M extends SerializationGroupMember<K,V,G>,C extends GroupAwareBackingCache<K,V,G,M>> |
getGroupCreationContext()
Gets the GroupCreationContext associated with the thread.
|
boolean |
isStrict()
Gets whether the cache that initialized creation of the context has specified that all other caches must strictly check
whether they are compatible with the group.
|
static <K extends Serializable,V extends Cacheable<K>,G extends Serializable,M extends SerializationGroupMember<K,V,G>,C extends GroupAwareBackingCache<K,V,G,M>> |
startGroupCreationContext(boolean strict)
Create a new GroupCreationContext associated with the thread.
|
public static <K extends Serializable,V extends Cacheable<K>,G extends Serializable,M extends SerializationGroupMember<K,V,G>,C extends GroupAwareBackingCache<K,V,G,M>> GroupCreationContext<K,V,G,M,C> getGroupCreationContext()
null
.public static <K extends Serializable,V extends Cacheable<K>,G extends Serializable,M extends SerializationGroupMember<K,V,G>,C extends GroupAwareBackingCache<K,V,G,M>> GroupCreationContext<K,V,G,M,C> startGroupCreationContext(boolean strict)
strict
- true
if other caches associated with the context should strictly check compatibility with a
SerializationGroup
, false
if not.null
.IllegalStateException
- if a context is already bound to the threadpublic static void clearGroupCreationContext()
public List<Map.Entry<V,C>> getEntries()
null
.public boolean isStrict()
Copyright © 2013 JBoss, a division of Red Hat, Inc.. All rights reserved.