public class AsyncContinuation extends Object implements javax.servlet.AsyncContext, Continuation
Modifier and Type | Class and Description |
---|---|
class |
AsyncContinuation.AsyncEventState |
class |
AsyncContinuation.AsyncTimeout |
Modifier and Type | Field and Description |
---|---|
protected AbstractHttpConnection |
_connection |
ASYNC_CONTEXT_PATH, ASYNC_PATH_INFO, ASYNC_QUERY_STRING, ASYNC_REQUEST_URI, ASYNC_SERVLET_PATH
ATTRIBUTE
Modifier | Constructor and Description |
---|---|
protected |
AsyncContinuation() |
Modifier and Type | Method and Description |
---|---|
void |
addContinuationListener(ContinuationListener listener) |
void |
addListener(javax.servlet.AsyncListener listener) |
void |
addListener(javax.servlet.AsyncListener listener,
javax.servlet.ServletRequest request,
javax.servlet.ServletResponse response) |
void |
cancel() |
protected void |
cancelTimeout() |
void |
complete() |
<T extends javax.servlet.AsyncListener> |
createListener(Class<T> clazz) |
void |
dispatch() |
void |
dispatch(javax.servlet.ServletContext context,
String path) |
void |
dispatch(String path) |
protected void |
doComplete(Throwable ex) |
protected void |
expired() |
AsyncContinuation.AsyncEventState |
getAsyncEventState() |
Object |
getAttribute(String name) |
Request |
getBaseRequest() |
ContextHandler |
getContextHandler() |
javax.servlet.ServletRequest |
getRequest() |
javax.servlet.ServletResponse |
getResponse() |
javax.servlet.ServletResponse |
getServletResponse() |
String |
getStatusString() |
long |
getTimeout() |
protected boolean |
handling() |
boolean |
hasOriginalRequestAndResponse() |
boolean |
isAsync() |
boolean |
isAsyncStarted() |
boolean |
isComplete() |
boolean |
isCompleting() |
boolean |
isContinuation() |
boolean |
isDispatchable() |
boolean |
isExpired() |
boolean |
isInitial() |
boolean |
isResponseWrapped() |
boolean |
isResumed() |
boolean |
isSuspended() |
boolean |
isSuspending() |
protected void |
recycle() |
void |
removeAttribute(String name) |
void |
resume() |
protected void |
scheduleDispatch() |
protected void |
scheduleTimeout() |
void |
setAttribute(String name,
Object attribute) |
protected void |
setConnection(AbstractHttpConnection connection) |
void |
setTimeout(long ms) |
void |
start(Runnable run) |
protected void |
startAsync() |
protected void |
startAsync(javax.servlet.ServletContext context,
javax.servlet.ServletRequest request,
javax.servlet.ServletResponse response) |
void |
suspend() |
void |
suspend(javax.servlet.ServletResponse response) |
String |
toString() |
void |
undispatch() |
protected boolean |
unhandle()
Signal that the HttpConnection has finished handling the request.
|
protected AbstractHttpConnection _connection
protected void setConnection(AbstractHttpConnection connection)
public void addListener(javax.servlet.AsyncListener listener)
addListener
in interface javax.servlet.AsyncContext
public void addListener(javax.servlet.AsyncListener listener, javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)
addListener
in interface javax.servlet.AsyncContext
public void addContinuationListener(ContinuationListener listener)
addContinuationListener
in interface Continuation
public void setTimeout(long ms)
setTimeout
in interface javax.servlet.AsyncContext
setTimeout
in interface Continuation
public long getTimeout()
getTimeout
in interface javax.servlet.AsyncContext
public AsyncContinuation.AsyncEventState getAsyncEventState()
public boolean isResponseWrapped()
isResponseWrapped
in interface Continuation
Continuation.isResponseWrapped()
public boolean isInitial()
isInitial
in interface Continuation
public boolean isContinuation()
public boolean isSuspended()
isSuspended
in interface Continuation
public boolean isSuspending()
public boolean isDispatchable()
public String getStatusString()
protected boolean handling()
protected boolean unhandle()
public void dispatch()
dispatch
in interface javax.servlet.AsyncContext
protected void expired()
public void complete()
complete
in interface javax.servlet.AsyncContext
complete
in interface Continuation
public <T extends javax.servlet.AsyncListener> T createListener(Class<T> clazz) throws javax.servlet.ServletException
createListener
in interface javax.servlet.AsyncContext
javax.servlet.ServletException
protected void doComplete(Throwable ex)
protected void recycle()
public void cancel()
protected void scheduleDispatch()
protected void scheduleTimeout()
protected void cancelTimeout()
public boolean isCompleting()
public boolean isComplete()
public boolean isAsyncStarted()
public boolean isAsync()
public void dispatch(javax.servlet.ServletContext context, String path)
dispatch
in interface javax.servlet.AsyncContext
public void dispatch(String path)
dispatch
in interface javax.servlet.AsyncContext
public Request getBaseRequest()
public javax.servlet.ServletRequest getRequest()
getRequest
in interface javax.servlet.AsyncContext
public javax.servlet.ServletResponse getResponse()
getResponse
in interface javax.servlet.AsyncContext
public void start(Runnable run)
start
in interface javax.servlet.AsyncContext
public boolean hasOriginalRequestAndResponse()
hasOriginalRequestAndResponse
in interface javax.servlet.AsyncContext
public ContextHandler getContextHandler()
public boolean isResumed()
isResumed
in interface Continuation
Continuation.isResumed()
public boolean isExpired()
isExpired
in interface Continuation
Continuation.isExpired()
public void resume()
resume
in interface Continuation
Continuation.resume()
protected void startAsync(javax.servlet.ServletContext context, javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)
protected void startAsync()
public void suspend(javax.servlet.ServletResponse response)
suspend
in interface Continuation
Continuation.suspend()
public void suspend()
suspend
in interface Continuation
Continuation.suspend()
public javax.servlet.ServletResponse getServletResponse()
getServletResponse
in interface Continuation
Continuation.getServletResponse()
public Object getAttribute(String name)
getAttribute
in interface Continuation
Continuation.getAttribute(java.lang.String)
public void removeAttribute(String name)
removeAttribute
in interface Continuation
Continuation.removeAttribute(java.lang.String)
public void setAttribute(String name, Object attribute)
setAttribute
in interface Continuation
Continuation.setAttribute(java.lang.String, java.lang.Object)
public void undispatch()
undispatch
in interface Continuation
Continuation.undispatch()
Copyright © 1995-2013 Mort Bay Consulting. All Rights Reserved.