Package io.quarkus.arc
Interface CurrentContextFactory
public interface CurrentContextFactory
This factory can be used to create a new
CurrentContext
for a normal scope.
For example, the current context for RequestScoped
. It's usually not necessary for shared
contexts, such as ApplicationScoped
.
-
Method Summary
Modifier and TypeMethodDescription<T extends InjectableContext.ContextState>
CurrentContext<T>create
(Class<? extends Annotation> scope)
-
Method Details
-
create
<T extends InjectableContext.ContextState> CurrentContext<T> create(Class<? extends Annotation> scope) - Type Parameters:
T
-- Parameters:
scope
-- Returns:
- the current context
- Throws:
IllegalStateException
- If the implementation does not support multiple current contexts for the same scope
-