Class ClassLoaderContextHandleFactory
- java.lang.Object
-
- org.jboss.as.ee.concurrent.handle.ClassLoaderContextHandleFactory
-
- All Implemented Interfaces:
ContextHandleFactory
public class ClassLoaderContextHandleFactory extends Object implements ContextHandleFactory
A context handle factory which is responsible for saving and setting proper classloading context.- Author:
- Eduardo Martins
-
-
Constructor Summary
Constructors Constructor Description ClassLoaderContextHandleFactory(ClassLoader classLoader)
-
Method Summary
All Methods Instance Methods Concrete 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.
-
-
-
Field Detail
-
NAME
public static final String NAME
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ClassLoaderContextHandleFactory
public ClassLoaderContextHandleFactory(ClassLoader classLoader)
-
-
Method Detail
-
saveContext
public SetupContextHandle saveContext(javax.enterprise.concurrent.ContextService contextService, Map<String,String> contextObjectProperties)
- Specified by:
saveContextin interfaceContextHandleFactory- Returns:
- See Also:
ContextSetupProvider.saveContext(javax.enterprise.concurrent.ContextService, java.util.Map)
-
getName
public String getName()
Description copied from interface:ContextHandleFactoryRetrieves the factory's name.- Specified by:
getNamein interfaceContextHandleFactory- Returns:
-
getChainPriority
public int getChainPriority()
Description copied from interface:ContextHandleFactoryThe factory priority is used to define the order of handles when chained. The handle with the lowest priority is the first in the chain.- Specified by:
getChainPriorityin interfaceContextHandleFactory- Returns:
-
writeSetupContextHandle
public void writeSetupContextHandle(SetupContextHandle contextHandle, ObjectOutputStream out) throws IOException
Description copied from interface:ContextHandleFactoryWrites the handle to the specified output stream.- Specified by:
writeSetupContextHandlein interfaceContextHandleFactory- Throws:
IOException
-
readSetupContextHandle
public SetupContextHandle readSetupContextHandle(ObjectInputStream in) throws IOException, ClassNotFoundException
Description copied from interface:ContextHandleFactoryReads a handle from the specified input stream.- Specified by:
readSetupContextHandlein interfaceContextHandleFactory- Returns:
- Throws:
IOExceptionClassNotFoundException
-
-