Class ServerHttp1StreamHandler
java.lang.Object
org.apache.hc.core5.http.impl.nio.ServerHttp1StreamHandler
- All Implemented Interfaces:
ResourceHolder
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ConnectionReuseStrategyprivate final HttpCoreContextprivate final AtomicBooleanprivate AsyncServerExchangeHandlerprivate final HandlerFactory<AsyncServerExchangeHandler> private final HttpProcessorprivate final DataStreamChannelprivate booleanprivate final Http1StreamChannel<HttpResponse> private HttpRequestprivate MessageStateprivate final ResponseChannelprivate final AtomicBooleanprivate MessageState -
Constructor Summary
ConstructorsConstructorDescriptionServerHttp1StreamHandler(Http1StreamChannel<HttpResponse> outputChannel, HttpProcessor httpProcessor, ConnectionReuseStrategy connectionReuseStrategy, HandlerFactory<AsyncServerExchangeHandler> exchangeHandlerFactory, HttpCoreContext context) -
Method Summary
Modifier and TypeMethodDescription(package private) void(package private) voidappendState(StringBuilder buf) private voidcommitInformation(HttpResponse response) private voidprivate voidcommitResponse(HttpResponse response, EntityDetails responseEntityDetails) (package private) voidconsumeData(ByteBuffer src) (package private) voidconsumeHeader(HttpRequest request, EntityDetails requestEntityDetails) (package private) void(package private) void(package private) boolean(package private) boolean(package private) boolean(package private) boolean(package private) voidvoid(package private) voidtoString()(package private) voidupdateCapacity(CapacityChannel capacityChannel)
-
Field Details
-
outputChannel
-
internalDataChannel
-
responseChannel
-
httpProcessor
-
exchangeHandlerFactory
-
connectionReuseStrategy
-
context
-
responseCommitted
-
done
-
keepAlive
private volatile boolean keepAlive -
exchangeHandler
-
receivedRequest
-
requestState
-
responseState
-
-
Constructor Details
-
ServerHttp1StreamHandler
ServerHttp1StreamHandler(Http1StreamChannel<HttpResponse> outputChannel, HttpProcessor httpProcessor, ConnectionReuseStrategy connectionReuseStrategy, HandlerFactory<AsyncServerExchangeHandler> exchangeHandlerFactory, HttpCoreContext context)
-
-
Method Details
-
commitResponse
private void commitResponse(HttpResponse response, EntityDetails responseEntityDetails) throws HttpException, IOException - Throws:
HttpExceptionIOException
-
commitInformation
- Throws:
IOExceptionHttpException
-
commitPromise
- Throws:
HttpException
-
activateChannel
- Throws:
IOExceptionHttpException
-
isResponseFinal
boolean isResponseFinal() -
keepAlive
boolean keepAlive() -
isCompleted
boolean isCompleted() -
terminateExchange
- Throws:
HttpExceptionIOException
-
consumeHeader
void consumeHeader(HttpRequest request, EntityDetails requestEntityDetails) throws HttpException, IOException - Throws:
HttpExceptionIOException
-
isOutputReady
boolean isOutputReady() -
produceOutput
- Throws:
HttpExceptionIOException
-
consumeData
- Throws:
HttpExceptionIOException
-
updateCapacity
- Throws:
IOException
-
dataEnd
- Throws:
HttpExceptionIOException
-
failed
-
releaseResources
public void releaseResources()- Specified by:
releaseResourcesin interfaceResourceHolder
-
appendState
-
toString
-