Class AsyncContextDelegateProviderImpl.ExtensionImpl
java.lang.Object
org.glassfish.jersey.servlet.async.AsyncContextDelegateProviderImpl.ExtensionImpl
- All Implemented Interfaces:
AsyncContextDelegate
- Enclosing class:
AsyncContextDelegateProviderImpl
private static final class AsyncContextDelegateProviderImpl.ExtensionImpl
extends Object
implements AsyncContextDelegate
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final AtomicReference<javax.servlet.AsyncContext> private final AtomicBooleanprivate static final intprivate final javax.servlet.http.HttpServletRequestprivate final javax.servlet.http.HttpServletResponse -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateExtensionImpl(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) -
Method Summary
Modifier and TypeMethodDescriptionvoidcomplete()Invoked upon a response writing completion when the response write is either committed or canceled.private javax.servlet.AsyncContextvoidsuspend()Invoked by the superiorContainerResponseWriterresponsible for writing the response when processing is to be suspended.
-
Field Details
-
NEVER_TIMEOUT_VALUE
private static final int NEVER_TIMEOUT_VALUE- See Also:
-
request
private final javax.servlet.http.HttpServletRequest request -
response
private final javax.servlet.http.HttpServletResponse response -
asyncContextRef
-
completed
-
-
Constructor Details
-
ExtensionImpl
private ExtensionImpl(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) - Parameters:
request- request to createAsyncContextfor.response- response to createAsyncContextfor.
-
-
Method Details
-
suspend
Description copied from interface:AsyncContextDelegateInvoked by the superiorContainerResponseWriterresponsible for writing the response when processing is to be suspended. An implementation can throw anUnsupportedOperationExceptionif suspend is not supported (the default behavior).- Specified by:
suspendin interfaceAsyncContextDelegate- Throws:
IllegalStateException- if underlyingservlet requestthrows an exception.- See Also:
-
getAsyncContext
private javax.servlet.AsyncContext getAsyncContext() -
complete
public void complete()Description copied from interface:AsyncContextDelegateInvoked upon a response writing completion when the response write is either committed or canceled.- Specified by:
completein interfaceAsyncContextDelegate
-