Package org.jboss.weld.contexts
Interface WeldCreationalContext<T>
-
- Type Parameters:
T
-
- All Superinterfaces:
jakarta.enterprise.context.spi.CreationalContext<T>
,org.jboss.weld.construction.api.WeldCreationalContext<T>
- All Known Implementing Classes:
CreationalContextImpl
public interface WeldCreationalContext<T> extends org.jboss.weld.construction.api.WeldCreationalContext<T>
- Author:
- pmuir
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addDependentInstance(org.jboss.weld.context.api.ContextualInstance<?> contextualInstance)
void
addDependentResourceReference(org.jboss.weld.injection.spi.ResourceReference<?> resourceReference)
Register aResourceReference
as a dependency.boolean
destroyDependentInstance(T instance)
Destroys dependent instancejakarta.enterprise.context.spi.Contextual<T>
getContextual()
<S> WeldCreationalContext<S>
getCreationalContext(jakarta.enterprise.context.spi.Contextual<S> contextual)
List<org.jboss.weld.context.api.ContextualInstance<?>>
getDependentInstances()
Returns an unmodifiable list of dependent instances.<S> S
getIncompleteInstance(jakarta.enterprise.context.spi.Contextual<S> bean)
WeldCreationalContext<?>
getParentCreationalContext()
<S> WeldCreationalContext<S>
getProducerReceiverCreationalContext(jakarta.enterprise.context.spi.Contextual<S> contextual)
The returnedCreationalContext
shares nothing but incomplete instances.void
release()
-
-
-
Method Detail
-
getCreationalContext
<S> WeldCreationalContext<S> getCreationalContext(jakarta.enterprise.context.spi.Contextual<S> contextual)
-
getProducerReceiverCreationalContext
<S> WeldCreationalContext<S> getProducerReceiverCreationalContext(jakarta.enterprise.context.spi.Contextual<S> contextual)
The returnedCreationalContext
shares nothing but incomplete instances.- Parameters:
contextual
-- Returns:
- the
CreationalContext
for a producer reciever
-
getIncompleteInstance
<S> S getIncompleteInstance(jakarta.enterprise.context.spi.Contextual<S> bean)
-
addDependentInstance
void addDependentInstance(org.jboss.weld.context.api.ContextualInstance<?> contextualInstance)
-
release
void release()
- Specified by:
release
in interfacejakarta.enterprise.context.spi.CreationalContext<T>
-
getParentCreationalContext
WeldCreationalContext<?> getParentCreationalContext()
- Returns:
- the parent
CreationalContext
or null if there isn't any parent.
-
getContextual
jakarta.enterprise.context.spi.Contextual<T> getContextual()
- Returns:
- the
Contextual
for which thisCreationalContext
is created.
-
getDependentInstances
List<org.jboss.weld.context.api.ContextualInstance<?>> getDependentInstances()
Returns an unmodifiable list of dependent instances.
-
destroyDependentInstance
boolean destroyDependentInstance(T instance)
Destroys dependent instance- Parameters:
instance
-- Returns:
- true if the instance was destroyed, false otherwise
-
addDependentResourceReference
void addDependentResourceReference(org.jboss.weld.injection.spi.ResourceReference<?> resourceReference)
Register aResourceReference
as a dependency.ResourceReference.release()
will be called on everyResourceReference
once thisCreationalContext
instance is released.
-
-