org.apache.hc.core5.http2.nio

## Interface AsyncPingHandler

- All Known Implementing Classes:
    BasicPingHandler

      public interface AsyncPingHandler

  Abstract asynchronous ping exchange handler.
  Since:
    5.0

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `cancel()` Triggered to cancel the message exchange.
    `void` | `consumeResponse(ByteBuffer feedback)` Triggered to signal receipt of a ping response message.
    `void` | `failed(Exception cause)` Triggered to signal a failure in data processing.
    `ByteBuffer` | `getData()` Returns content of ping message.

- - ### Method Detail

    - #### getData

          ByteBuffer getData()

      Returns content of ping message.
      Returns:
        the ping message content.

    - #### consumeResponse

          void consumeResponse(ByteBuffer feedback)
                               throws HttpException,
                                      IOException

      Triggered to signal receipt of a ping response message.
      Parameters:
        `feedback` - the ping message feedback.
      Throws:
        `HttpException`
        `IOException`

    - #### failed

          void failed(Exception cause)

      Triggered to signal a failure in data processing.
      Parameters:
        `cause` - the cause of the failure.

    - #### cancel

          void cancel()

      Triggered to cancel the message exchange.

Copyright © 2005–2020 The Apache Software Foundation. All rights reserved.