org.apache.hc.core5.http.nio

## Interface AsyncServerRequestHandler.ResponseTrigger

- Enclosing interface:
    AsyncServerRequestHandler<T>

      public static interface AsyncServerRequestHandler.ResponseTrigger

  Response trigger that can be used to submit a final HTTP response and terminate HTTP request processing.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `pushPromise(HttpRequest promise, HttpContext context, AsyncPushProducer responseProducer)` Pushes a request message head as a promise to deliver a response message.
    `void` | `sendInformation(HttpResponse response, HttpContext context)` Sends an intermediate informational HTTP response to the client.
    `void` | `submitResponse(AsyncResponseProducer responseProducer, HttpContext context)` Sends a final HTTP response to the client.

- - ### Method Detail

    - #### sendInformation

          void sendInformation(HttpResponse response,
                             HttpContext context)
                               throws HttpException,
                                      IOException

      Sends an intermediate informational HTTP response to the client.
      Parameters:
        `response` - the intermediate (1xx) HTTP response
        `context` - the actual execution context.
      Throws:
        `HttpException`
        `IOException`

    - #### submitResponse

          void submitResponse(AsyncResponseProducer responseProducer,
                            HttpContext context)
                              throws HttpException,
                                     IOException

      Sends a final HTTP response to the client.
      Parameters:
        `responseProducer` - the HTTP response message producer.
        `context` - the actual execution context.
      Throws:
        `HttpException`
        `IOException`

    - #### pushPromise

          void pushPromise(HttpRequest promise,
                         HttpContext context,
                         AsyncPushProducer responseProducer)
                           throws HttpException,
                                  IOException

      Pushes a request message head as a promise to deliver a response message.
      Parameters:
        `promise` - the request message header used as a promise.
        `context` - the actual execution context.
        `responseProducer` - the push response message producer.
      Throws:
        `HttpException`
        `IOException`

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