Package org.glassfish.internal.api
Interface JavaEEContextUtil
-
- All Superinterfaces:
ContextProducer
- All Known Implementing Classes:
JavaEEContextUtilImpl
@Contract public interface JavaEEContextUtil extends ContextProducer
utility to create / push Java EE thread context- Author:
- lprimak
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
JavaEEContextUtil.Context
static interface
JavaEEContextUtil.Instance
-
Nested classes/interfaces inherited from interface org.glassfish.internal.api.ContextProducer
ContextProducer.Closeable
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description JavaEEContextUtil.Instance
currentInvocation()
captures current invocation and returns it as an instanceJavaEEContextUtil.Instance
empty()
Creates an empty instance, i.e.JavaEEContextUtil.Instance
fromComponentId(String componentId)
-
Methods inherited from interface org.glassfish.internal.api.ContextProducer
getInvocationClassLoader, getInvocationComponentId, isInvocationLoaded, moduleMatches
-
-
-
-
Method Detail
-
empty
JavaEEContextUtil.Instance empty()
Description copied from interface:ContextProducer
Creates an empty instance, i.e. if the empty context is pushed on top of another context, the other context will be 'suppressed' for the duration of this context- Specified by:
empty
in interfaceContextProducer
- Returns:
- new empty instance
-
currentInvocation
JavaEEContextUtil.Instance currentInvocation() throws IllegalStateException
Description copied from interface:ContextProducer
captures current invocation and returns it as an instance- Specified by:
currentInvocation
in interfaceContextProducer
- Returns:
- new captured instance
- Throws:
IllegalStateException
-
fromComponentId
JavaEEContextUtil.Instance fromComponentId(String componentId) throws IllegalArgumentException
- Parameters:
componentId
- component id for this instance, non-null- Returns:
- new instance based on componentId
- Throws:
IllegalArgumentException
-
-