Receiver.ErrorCallback, Receiver.FullBytesCallback, Receiver.FullStringCallback, Receiver.PartialBytesCallback, Receiver.PartialStringCallback, Receiver.RequestToLargeException| Modifier and Type | Field and Description |
|---|---|
static byte[] | EMPTY_BYTE_ARRAY |
| Constructor and Description |
|---|
AsyncReceiverImpl(HttpServerExchange exchange) |
| Modifier and Type | Method and Description |
|---|---|
void | pause() When receiving partial data calling this method will pause the callbacks. |
void | receiveFullBytes(Receiver.FullBytesCallback callback) Reads the request and invokes the callback when the request body has been fully read. |
void | receiveFullBytes(Receiver.FullBytesCallback callback, Receiver.ErrorCallback errorCallback) Reads the request and invokes the callback when the request body has been fully read. |
void | receiveFullString(Receiver.FullStringCallback callback) Reads the request and invokes the callback when the request body has been fully read. |
void | receiveFullString(Receiver.FullStringCallback callback, Charset charset) Reads the request and invokes the callback when the request body has been fully read. |
void | receiveFullString(Receiver.FullStringCallback callback, Receiver.ErrorCallback errorCallback) Reads the request and invokes the callback when the request body has been fully read. |
void | receiveFullString(Receiver.FullStringCallback callback, Receiver.ErrorCallback errorCallback, Charset charset) Reads the request and invokes the callback when the request body has been fully read. |
void | receivePartialBytes(Receiver.PartialBytesCallback callback) Reads the request and invokes the callback with request data. |
void | receivePartialBytes(Receiver.PartialBytesCallback callback, Receiver.ErrorCallback errorCallback) Reads the request and invokes the callback with request data. |
void | receivePartialString(Receiver.PartialStringCallback callback) Reads the request and invokes the callback with request data. |
void | receivePartialString(Receiver.PartialStringCallback callback, Charset charset) Reads the request and invokes the callback with request data. |
void | receivePartialString(Receiver.PartialStringCallback callback, Receiver.ErrorCallback errorCallback) Reads the request and invokes the callback with request data. |
void | receivePartialString(Receiver.PartialStringCallback callback, Receiver.ErrorCallback errorCallback, Charset charset) Reads the request and invokes the callback with request data. |
void | resume() Resumes paused callbacks. |
void | setMaxBufferSize(int maxBufferSize) Sets the maximum amount of data that will be buffered in memory. |
public AsyncReceiverImpl(HttpServerExchange exchange)
public void setMaxBufferSize(int maxBufferSize)
ReceiverRequestTooBigException.setMaxBufferSize in interface ReceivermaxBufferSize - The maximum amount of data to be bufferedpublic void receiveFullString(Receiver.FullStringCallback callback, Receiver.ErrorCallback errorCallback)
ReceiverStandardCharsets.ISO_8859_1. If there is an error reading the request the error callback will be invoked.receiveFullString in interface Receivercallback - The callback to invoke with the requesterrorCallback - The callback that is invoked on errorpublic void receiveFullString(Receiver.FullStringCallback callback)
ReceiverStandardCharsets.ISO_8859_1. If there is an error the exchange will be ended.receiveFullString in interface Receivercallback - The callback to invoke with the requestpublic void receivePartialString(Receiver.PartialStringCallback callback, Receiver.ErrorCallback errorCallback)
ReceiverStandardCharsets.ISO_8859_1. If there is an error reading the request the error callback will be invoked.receivePartialString in interface Receivercallback - The callback to invoke with the requesterrorCallback - The callback that is invoked on errorpublic void receivePartialString(Receiver.PartialStringCallback callback)
ReceiverStandardCharsets.ISO_8859_1. If there is an error the exchange will be ended.receivePartialString in interface Receivercallback - The callback to invoke with the requestpublic void receiveFullString(Receiver.FullStringCallback callback, Receiver.ErrorCallback errorCallback, Charset charset)
ReceiverreceiveFullString in interface Receivercallback - The callback to invoke with the requesterrorCallback - The callback that is invoked on errorcharset - The charset that is used to interpret the stringpublic void receiveFullString(Receiver.FullStringCallback callback, Charset charset)
ReceiverreceiveFullString in interface Receivercallback - The callback to invoke with the requestcharset - The charset that is used to interpret the stringpublic void receivePartialString(Receiver.PartialStringCallback callback, Receiver.ErrorCallback errorCallback, Charset charset)
ReceiverreceivePartialString in interface Receivercallback - The callback to invoke with the requesterrorCallback - The callback that is invoked on errorcharset - The charset that is used to interpret the stringpublic void receivePartialString(Receiver.PartialStringCallback callback, Charset charset)
ReceiverreceivePartialString in interface Receivercallback - The callback to invoke with the requestcharset - The charset that is used to interpret the stringpublic void receiveFullBytes(Receiver.FullBytesCallback callback, Receiver.ErrorCallback errorCallback)
ReceiverreceiveFullBytes in interface Receivercallback - The callback to invoke with the requesterrorCallback - The callback that is invoked on errorpublic void receiveFullBytes(Receiver.FullBytesCallback callback)
ReceiverreceiveFullBytes in interface Receivercallback - The callback to invoke with the requestpublic void receivePartialBytes(Receiver.PartialBytesCallback callback, Receiver.ErrorCallback errorCallback)
ReceiverreceivePartialBytes in interface Receivercallback - The callback to invoke with the requesterrorCallback - The callback that is invoked on errorpublic void receivePartialBytes(Receiver.PartialBytesCallback callback)
ReceiverreceivePartialBytes in interface Receivercallback - The callback to invoke with the requestpublic void pause()
ReceiverReceiver.resume() has been called.Copyright © 2020 JBoss by Red Hat. All rights reserved.