org.apache.hc.client5.http.async.methods

## Class SimpleResponseConsumer

- java.lang.Object
- - org.apache.hc.core5.http.nio.support.AbstractAsyncResponseConsumer<SimpleHttpResponse,byte[]>
  - - org.apache.hc.client5.http.async.methods.SimpleResponseConsumer

All Implemented Interfaces:
  AsyncDataConsumer, AsyncResponseConsumer<SimpleHttpResponse>, ResourceHolder

    public final class SimpleResponseConsumer
    extends AbstractAsyncResponseConsumer<SimpleHttpResponse,byte[]>

HTTP response consumer that generates a `SimpleHttpResponse` instance based on events of an incoming data stream.

Since:
  5.0
See Also:
  `SimpleBody`

### Method Summary

Methods
`protected SimpleHttpResponse` `buildResult(HttpResponse response, byte[] entity, ContentType contentType)`
`static SimpleResponseConsumer` `create()`
`void` `informationResponse(HttpResponse response, HttpContext context)`

### Methods inherited from class org.apache.hc.core5.http.nio.support.AbstractAsyncResponseConsumer

`consume, consumeResponse, failed, getException, getResult, releaseResources, streamEnd, updateCapacity`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Method Detail

#### create

    public static SimpleResponseConsumer create()

#### informationResponse

    public void informationResponse(HttpResponse response,
                           HttpContext context)
                             throws HttpException,
                                    IOException

Throws:
  `HttpException`
  `IOException`

#### buildResult

    protected SimpleHttpResponse buildResult(HttpResponse response,
                                 byte[] entity,
                                 ContentType contentType)

Specified by:
  `buildResult` in class `AbstractAsyncResponseConsumer<SimpleHttpResponse,byte[]>`