org.apache.hc.core5.http.nio.support

## Class AsyncPushBuilder

- java.lang.Object
- - org.apache.hc.core5.http.support.AbstractMessageBuilder<T>
  - - org.apache.hc.core5.http.support.AbstractResponseBuilder<AsyncPushProducer>
    - - org.apache.hc.core5.http.nio.support.AsyncPushBuilder

-     public class AsyncPushBuilder
      extends AbstractResponseBuilder<AsyncPushProducer>

  Builder for `AsyncPushProducer` instances.
  Since:
    5.0

- - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `AsyncPushBuilder` | `addHeader(Header header)`
    `AsyncPushBuilder` | `addHeader(String name, String value)`
    `AsyncPushProducer` | `build()`
    `static AsyncPushBuilder` | `create(int status)`
    `AsyncEntityProducer` | `getEntity()`
    `AsyncPushBuilder` | `removeHeader(Header header)`
    `AsyncPushBuilder` | `removeHeaders(String name)`
    `AsyncPushBuilder` | `setEntity(AsyncEntityProducer entityProducer)`
    `AsyncPushBuilder` | `setEntity(byte[] content, ContentType contentType)`
    `AsyncPushBuilder` | `setEntity(String content)`
    `AsyncPushBuilder` | `setEntity(String content, ContentType contentType)`
    `AsyncPushBuilder` | `setHeader(Header header)`
    `AsyncPushBuilder` | `setHeader(String name, String value)`
    `AsyncPushBuilder` | `setHeaders(Header... headers)`
    `AsyncPushBuilder` | `setVersion(ProtocolVersion version)`
    `String` | `toString()`

    - ### Methods inherited from class org.apache.hc.core5.http.support.AbstractResponseBuilder

      `getStatus, setStatus`

    - ### Methods inherited from class org.apache.hc.core5.http.support.AbstractMessageBuilder

      `digest, getFirstHeader, getFirstHeaders, getHeaders, getHeaders, getLastHeader, getVersion, setHeaders`

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

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

- - ### Method Detail

    - #### create

          public static AsyncPushBuilder create(int status)

    - #### setVersion

          public AsyncPushBuilder setVersion(ProtocolVersion version)

      Overrides:
        `setVersion` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### setHeaders

          public AsyncPushBuilder setHeaders(Header... headers)

      Overrides:
        `setHeaders` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### addHeader

          public AsyncPushBuilder addHeader(Header header)

      Overrides:
        `addHeader` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### addHeader

          public AsyncPushBuilder addHeader(String name,
                                            String value)

      Overrides:
        `addHeader` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### removeHeader

          public AsyncPushBuilder removeHeader(Header header)

      Overrides:
        `removeHeader` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### removeHeaders

          public AsyncPushBuilder removeHeaders(String name)

      Overrides:
        `removeHeaders` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### setHeader

          public AsyncPushBuilder setHeader(Header header)

      Overrides:
        `setHeader` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### setHeader

          public AsyncPushBuilder setHeader(String name,
                                            String value)

      Overrides:
        `setHeader` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### getEntity

          public AsyncEntityProducer getEntity()

    - #### setEntity

          public AsyncPushBuilder setEntity(AsyncEntityProducer entityProducer)

    - #### setEntity

          public AsyncPushBuilder setEntity(String content,
                                            ContentType contentType)

    - #### setEntity

          public AsyncPushBuilder setEntity(String content)

    - #### setEntity

          public AsyncPushBuilder setEntity(byte[] content,
                                            ContentType contentType)

    - #### build

          public AsyncPushProducer build()

      Specified by:
        `build` in class `AbstractResponseBuilder<AsyncPushProducer>`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

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