Class BasicPingHandler
java.lang.Object
org.apache.hc.core5.http2.nio.support.BasicPingHandler
- All Implemented Interfaces:
AsyncPingHandler
Basic
AsyncPingHandler implementation.- Since:
- 5.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final byte[] -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcancel()Triggered to cancel the message exchange.voidconsumeResponse(ByteBuffer feedback) Triggered to signal receipt of a ping response message.voidTriggered to signal a failure in data processing.getData()Returns content of ping message.
-
Field Details
-
PING_MESSAGE
private static final byte[] PING_MESSAGE -
callback
-
-
Constructor Details
-
BasicPingHandler
-
-
Method Details
-
getData
Description copied from interface:AsyncPingHandlerReturns content of ping message.- Specified by:
getDatain interfaceAsyncPingHandler- Returns:
- the ping message content.
-
consumeResponse
Description copied from interface:AsyncPingHandlerTriggered to signal receipt of a ping response message.- Specified by:
consumeResponsein interfaceAsyncPingHandler- Parameters:
feedback- the ping message feedback.- Throws:
HttpExceptionIOException
-
failed
Description copied from interface:AsyncPingHandlerTriggered to signal a failure in data processing.- Specified by:
failedin interfaceAsyncPingHandler- Parameters:
cause- the cause of the failure.
-
cancel
public void cancel()Description copied from interface:AsyncPingHandlerTriggered to cancel the message exchange.- Specified by:
cancelin interfaceAsyncPingHandler
-