Package org.jboss.weld.contexts
Class AbstractBoundContext<S>
- java.lang.Object
-
- org.jboss.weld.contexts.AbstractContext
-
- org.jboss.weld.contexts.AbstractManagedContext
-
- org.jboss.weld.contexts.AbstractBoundContext<S>
-
- All Implemented Interfaces:
jakarta.enterprise.context.spi.AlterableContext
,jakarta.enterprise.context.spi.Context
,org.jboss.weld.context.BoundContext<S>
,org.jboss.weld.context.ManagedContext
,org.jboss.weld.context.WeldAlterableContext
- Direct Known Subclasses:
AbstractConversationContext
,BoundRequestContextImpl
,BoundSessionContextImpl
public abstract class AbstractBoundContext<S> extends AbstractManagedContext implements org.jboss.weld.context.BoundContext<S>
Base class for contexts using a thread local to store a bound bean context- Author:
- Pete Muir
-
-
Constructor Summary
Constructors Constructor Description AbstractBoundContext(String contextId, boolean multithreaded)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
activate()
void
cleanup()
void
clearAndSet(Collection<org.jboss.weld.context.api.ContextualInstance<?>> setOfInstances)
void
deactivate()
boolean
dissociate(S storage)
Collection<org.jboss.weld.context.api.ContextualInstance<?>>
getAllContextualInstances()
protected BoundBeanStore
getBeanStore()
Gets the bean storeprotected void
setBeanStore(BoundBeanStore beanStore)
Sets the bean store-
Methods inherited from class org.jboss.weld.contexts.AbstractManagedContext
invalidate, isActive, isValid, removeState, setActive
-
Methods inherited from class org.jboss.weld.contexts.AbstractContext
checkContextInitialized, destroy, destroy, get, get, getContextual, getId, getServiceRegistry, isMultithreaded
-
-
-
-
Constructor Detail
-
AbstractBoundContext
public AbstractBoundContext(String contextId, boolean multithreaded)
-
-
Method Detail
-
getBeanStore
protected BoundBeanStore getBeanStore()
Gets the bean store- Specified by:
getBeanStore
in classAbstractContext
- Returns:
- The bean store
-
setBeanStore
protected void setBeanStore(BoundBeanStore beanStore)
Sets the bean store- Parameters:
beanStore
- The bean store
-
cleanup
public void cleanup()
- Overrides:
cleanup
in classAbstractContext
-
activate
public void activate()
- Specified by:
activate
in interfaceorg.jboss.weld.context.ManagedContext
- Overrides:
activate
in classAbstractManagedContext
-
deactivate
public void deactivate()
- Specified by:
deactivate
in interfaceorg.jboss.weld.context.ManagedContext
- Overrides:
deactivate
in classAbstractManagedContext
-
dissociate
public boolean dissociate(S storage)
- Specified by:
dissociate
in interfaceorg.jboss.weld.context.BoundContext<S>
-
getAllContextualInstances
public Collection<org.jboss.weld.context.api.ContextualInstance<?>> getAllContextualInstances()
- Specified by:
getAllContextualInstances
in interfaceorg.jboss.weld.context.WeldAlterableContext
-
clearAndSet
public void clearAndSet(Collection<org.jboss.weld.context.api.ContextualInstance<?>> setOfInstances)
- Specified by:
clearAndSet
in interfaceorg.jboss.weld.context.WeldAlterableContext
-
-