public abstract class UpgradeProcessorBase extends AbstractProcessorLight implements WebConnection
Modifier and Type | Field and Description |
---|---|
protected static int |
INFINITE_TIMEOUT |
Constructor and Description |
---|
UpgradeProcessorBase(UpgradeToken upgradeToken) |
Modifier and Type | Method and Description |
---|---|
AbstractEndpoint.Handler.SocketState |
asyncPostProcess() |
ByteBuffer |
getLeftoverInput()
Allows retrieving additional input during the upgrade process
|
Request |
getRequest() |
UpgradeToken |
getUpgradeToken() |
boolean |
isAsync() |
boolean |
isUpgrade() |
void |
recycle()
Recycle the processor, ready for the next request which may be on the
same connection or a different connection.
|
AbstractEndpoint.Handler.SocketState |
service(SocketWrapperBase<?> socketWrapper)
Service a 'standard' HTTP request.
|
void |
timeoutAsync(long now)
Check this processor to see if the async timeout has expired and process
a timeout if that is that case.
|
addDispatch, clearDispatches, dispatch, getIteratorAndClearDispatches, getLog, process
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getInputStream, getOutputStream
close
pause, setSslSupport
protected static final int INFINITE_TIMEOUT
public UpgradeProcessorBase(UpgradeToken upgradeToken)
public UpgradeToken getUpgradeToken()
getUpgradeToken
in interface Processor
public final void recycle()
Processor
public final AbstractEndpoint.Handler.SocketState service(SocketWrapperBase<?> socketWrapper) throws IOException
AbstractProcessorLight
AbstractProcessorLight.dispatch(SocketEvent)
. Requests may be pipe-lined.service
in class AbstractProcessorLight
socketWrapper
- The connection to processIOException
- If an I/O error occurs during the processing of the
requestpublic final AbstractEndpoint.Handler.SocketState asyncPostProcess()
asyncPostProcess
in class AbstractProcessorLight
public final Request getRequest()
getRequest
in interface Processor
public ByteBuffer getLeftoverInput()
Processor
getLeftoverInput
in interface Processor
public void timeoutAsync(long now)
Processor
timeoutAsync
in interface Processor
now
- The time (as returned by System.currentTimeMillis()
to
use as the current time to determine whether the async timeout
has expired. If negative, the timeout will always be treated
as if it has expired.Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.