public class ServletBridgeManagedObjectSource extends AbstractManagedObjectSource<None,ServletBridgeManagedObjectSource.FlowKeys>
ManagedObjectSource
to trigger a ProcessState
to service a
HttpServletRequest
via providing a ServletBridge
.Modifier and Type | Class and Description |
---|---|
static class |
ServletBridgeManagedObjectSource.CompleteAsyncContextTask
Task to complete the AsyncContext . |
static class |
ServletBridgeManagedObjectSource.FlowKeys
Flow keys for the
ServletBridgeManagedObjectSource . |
AbstractAsyncManagedObjectSource.DependencyLabeller, AbstractAsyncManagedObjectSource.Labeller, AbstractAsyncManagedObjectSource.MetaDataContext<D extends Enum<D>,F extends Enum<F>>, AbstractAsyncManagedObjectSource.SpecificationContext
Modifier and Type | Field and Description |
---|---|
static String[] |
DEPENDENCY_ANNOTATION_TYPE_NAMES
Type names for the dependency annotations.
|
static String |
PROPERTY_INSTANCE_IDENTIFIER
Name of property identifying the instance of the
Servlet . |
static String |
PROPERTY_USE_ASYNC
Name of property identifying whether to use
AsyncContext
servicing. |
Constructor and Description |
---|
ServletBridgeManagedObjectSource() |
sourceManagedObject
getMetaData, getSpecification, init, stop
public static final String[] DEPENDENCY_ANNOTATION_TYPE_NAMES
public static final String PROPERTY_INSTANCE_IDENTIFIER
Servlet
.public static final String PROPERTY_USE_ASYNC
AsyncContext
servicing.public static <S> ServletServiceBridger<S> createServletServiceBridger(Class<S> servletClass, AutoWireOfficeFloorSource source, String handlerSectionName, String handlerInputName)
ServletServiceBridger
and also
configure into the AutoWireOfficeFloorSource
.S
- Servlet
type.servletClass
- Servlet
class.source
- AutoWireOfficeFloorSource
.handlerSectionName
- Name of the section to handle the HTTP request.handlerInputName
- Name of the input on the section to handle the HTTP request.ServletServiceBridger
.public static <S> ServletServiceBridger<S> createServletServiceBridger(Class<S> servletClass)
ServletServiceBridger
for the Servlet
.S
- Servlet
type.servletClass
- Class of the Servlet
.ServletServiceBridger
for the Servlet
.protected void loadSpecification(AbstractAsyncManagedObjectSource.SpecificationContext context)
AbstractAsyncManagedObjectSource
loadSpecification
in class AbstractAsyncManagedObjectSource<None,ServletBridgeManagedObjectSource.FlowKeys>
context
- Specifications.protected void loadMetaData(AbstractAsyncManagedObjectSource.MetaDataContext<None,ServletBridgeManagedObjectSource.FlowKeys> context) throws Exception
AbstractAsyncManagedObjectSource
loadMetaData
in class AbstractAsyncManagedObjectSource<None,ServletBridgeManagedObjectSource.FlowKeys>
context
- Meta-data.Exception
- If fails to load the meta-data.public void start(ManagedObjectExecuteContext<ServletBridgeManagedObjectSource.FlowKeys> context) throws Exception
ManagedObjectSource
Called once after ManagedObjectSource.init(ManagedObjectSourceContext)
to indicate
this ManagedObjectSource
should start execution.
On invocation of this method, ProcessState
instances may be
invoked via the ManagedObjectExecuteContext
.
start
in interface ManagedObjectSource<None,ServletBridgeManagedObjectSource.FlowKeys>
start
in class AbstractAsyncManagedObjectSource<None,ServletBridgeManagedObjectSource.FlowKeys>
context
- ManagedObjectExecuteContext
to use in starting this
ManagedObjectSource
.Exception
- Should the ManagedObjectSource
fail to start
execution.protected ManagedObject getManagedObject() throws Throwable
AbstractManagedObjectSource
ManagedObject
.getManagedObject
in class AbstractManagedObjectSource<None,ServletBridgeManagedObjectSource.FlowKeys>
ManagedObject
.Throwable
- If fails to obtain the ManagedObject
.Copyright © 2005–2016. All rights reserved.