public class AsyncContextImpl extends java.lang.Object implements AsyncContext, AsyncContextCallback
Modifier and Type | Field and Description |
---|---|
protected static StringManager |
sm |
ASYNC_CONTEXT_PATH, ASYNC_PATH_INFO, ASYNC_QUERY_STRING, ASYNC_REQUEST_URI, ASYNC_SERVLET_PATH
Constructor and Description |
---|
AsyncContextImpl(Request request) |
Modifier and Type | Method and Description |
---|---|
void |
addListener(AsyncListener listener) |
void |
addListener(AsyncListener listener,
ServletRequest servletRequest,
ServletResponse servletResponse) |
void |
complete() |
<T extends AsyncListener> |
createListener(java.lang.Class<T> clazz) |
void |
dispatch() |
void |
dispatch(ServletContext context,
java.lang.String path) |
void |
dispatch(java.lang.String path) |
protected void |
doInternalDispatch() |
void |
fireOnComplete() |
ServletRequest |
getRequest() |
ServletResponse |
getResponse() |
long |
getTimeout()
Get timeout in milliseconds. 0 or less indicates no timeout.
|
boolean |
hasOriginalRequestAndResponse() |
boolean |
isStarted() |
void |
recycle() |
void |
setErrorState(java.lang.Throwable t,
boolean fireOnError) |
void |
setStarted(Context context,
ServletRequest request,
ServletResponse response,
boolean originalRequestResponse) |
void |
setTimeout(long timeout)
Set timeout in milliseconds. 0 or less indicates no timeout.
|
void |
start(java.lang.Runnable run) |
boolean |
timeout() |
protected static final StringManager sm
public AsyncContextImpl(Request request)
public void complete()
complete
in interface AsyncContext
public void fireOnComplete()
fireOnComplete
in interface AsyncContextCallback
public boolean timeout()
public void dispatch()
dispatch
in interface AsyncContext
public void dispatch(java.lang.String path)
dispatch
in interface AsyncContext
public void dispatch(ServletContext context, java.lang.String path)
dispatch
in interface AsyncContext
public ServletRequest getRequest()
getRequest
in interface AsyncContext
public ServletResponse getResponse()
getResponse
in interface AsyncContext
public void start(java.lang.Runnable run)
start
in interface AsyncContext
public void addListener(AsyncListener listener)
addListener
in interface AsyncContext
public void addListener(AsyncListener listener, ServletRequest servletRequest, ServletResponse servletResponse)
addListener
in interface AsyncContext
public <T extends AsyncListener> T createListener(java.lang.Class<T> clazz) throws ServletException
createListener
in interface AsyncContext
ServletException
public void recycle()
public boolean isStarted()
public void setStarted(Context context, ServletRequest request, ServletResponse response, boolean originalRequestResponse)
public boolean hasOriginalRequestAndResponse()
hasOriginalRequestAndResponse
in interface AsyncContext
protected void doInternalDispatch() throws ServletException, java.io.IOException
ServletException
java.io.IOException
public long getTimeout()
javax.servlet.AsyncContext
getTimeout
in interface AsyncContext
public void setTimeout(long timeout)
javax.servlet.AsyncContext
setTimeout
in interface AsyncContext
public void setErrorState(java.lang.Throwable t, boolean fireOnError)
Copyright © 2000-2015 Apache Software Foundation. All Rights Reserved.