public abstract class AbstractContext extends Object implements AlterableContext
contexts.SharedContext
,
BasicContext
Constructor and Description |
---|
AbstractContext(boolean multithreaded)
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
cleanup() |
protected void |
destroy()
Destroys the context
|
void |
destroy(Contextual<?> contextual)
Destroy the existing contextual instance.
|
<T> T |
get(Contextual<T> contextual)
Return an existing instance of a certain contextual type or a null value.
|
<T> T |
get(Contextual<T> contextual,
CreationalContext<T> creationalContext)
Get the bean if it exists in the contexts.
|
protected abstract BeanStore |
getBeanStore()
A method that returns the actual bean store implementation
|
protected static <T> Contextual<T> |
getContextual(String id) |
protected String |
getId(Contextual<?> contextual) |
protected ServiceRegistry |
getServiceRegistry() |
public <T> T get(Contextual<T> contextual, CreationalContext<T> creationalContext)
get
in interface Context
T
- the type of contextual typecontextual
- the contextual typecreationalContext
- the context in which the new instance will be createdContextNotActiveException
- if the context is not activejavax.enterprise.context.spi.Context#get(BaseBean, boolean)
public <T> T get(Contextual<T> contextual)
Context
public void destroy(Contextual<?> contextual)
AlterableContext
Destroy the existing contextual instance. If there is no existing instance, no action is taken.
destroy
in interface AlterableContext
contextual
- the contextual typeprotected void destroy()
protected abstract BeanStore getBeanStore()
public void cleanup()
protected static <T> Contextual<T> getContextual(String id)
protected String getId(Contextual<?> contextual)
protected ServiceRegistry getServiceRegistry()
Copyright © 2013 Seam Framework. All Rights Reserved.