Interface ContextHandleFactory
-
- All Known Implementing Classes:
ClassLoaderContextHandleFactory,NamingContextHandleFactory,OtherEESetupActionsContextHandleFactory
public interface ContextHandleFactoryThe factory responsible for creating the context handles with the current context saved- Author:
- Eduardo Martins
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intgetChainPriority()The factory priority is used to define the order of handles when chained.StringgetName()Retrieves the factory's name.SetupContextHandlereadSetupContextHandle(ObjectInputStream in)Reads a handle from the specified input stream.SetupContextHandlesaveContext(javax.enterprise.concurrent.ContextService contextService, Map<String,String> contextObjectProperties)voidwriteSetupContextHandle(SetupContextHandle contextHandle, ObjectOutputStream out)Writes the handle to the specified output stream.
-
-
-
Method Detail
-
saveContext
SetupContextHandle saveContext(javax.enterprise.concurrent.ContextService contextService, Map<String,String> contextObjectProperties)
- Parameters:
contextService-contextObjectProperties-- Returns:
- See Also:
ContextSetupProvider.saveContext(javax.enterprise.concurrent.ContextService, java.util.Map)
-
getChainPriority
int getChainPriority()
The factory priority is used to define the order of handles when chained. The handle with the lowest priority is the first in the chain.- Returns:
-
getName
String getName()
Retrieves the factory's name.- Returns:
-
writeSetupContextHandle
void writeSetupContextHandle(SetupContextHandle contextHandle, ObjectOutputStream out) throws IOException
Writes the handle to the specified output stream.- Parameters:
contextHandle-out-- Throws:
IOException
-
readSetupContextHandle
SetupContextHandle readSetupContextHandle(ObjectInputStream in) throws IOException, ClassNotFoundException
Reads a handle from the specified input stream.- Parameters:
in-- Returns:
- Throws:
IOExceptionClassNotFoundException
-
-