org.apache.hc.core5.http.impl

## Class BasicEntityDetails

- java.lang.Object
- - org.apache.hc.core5.http.impl.BasicEntityDetails

- All Implemented Interfaces:
    EntityDetails

      public final class BasicEntityDetails
      extends Object
      implements EntityDetails

  Basic HTTP message entity details.
  Since:
    5.0

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `BasicEntityDetails(long len, ContentType contentType)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `getContentEncoding()` Gets content encoding of this entity, if known.
    `long` | `getContentLength()` Gets length of this entity, if known.
    `String` | `getContentType()` Gets content type of this entity, if known.
    `Set<String>` | `getTrailerNames()` Gets the preliminary declaration of trailing headers.
    `boolean` | `isChunked()` Tests the chunked transfer hint for this entity.

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

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

- - ### Constructor Detail

    - #### BasicEntityDetails

          public BasicEntityDetails(long len,
                                    ContentType contentType)

  - ### Method Detail

    - #### getContentLength

          public long getContentLength()

      Description copied from interface: `EntityDetails`
      Gets length of this entity, if known.
      Specified by:
        `getContentLength` in interface `EntityDetails`
      Returns:
        the length of this entity, may be `0`.

    - #### getContentType

          public String getContentType()

      Description copied from interface: `EntityDetails`
      Gets content type of this entity, if known.
      Specified by:
        `getContentType` in interface `EntityDetails`
      Returns:
        the content type of this entity, may be `null`.

    - #### getContentEncoding

          public String getContentEncoding()

      Description copied from interface: `EntityDetails`
      Gets content encoding of this entity, if known.
      Specified by:
        `getContentEncoding` in interface `EntityDetails`
      Returns:
        the content encoding of this entity, may be `null`.

    - #### isChunked

          public boolean isChunked()

      Description copied from interface: `EntityDetails`
      Tests the chunked transfer hint for this entity.

      The behavior of wrapping entities is implementation dependent, but should respect the primary purpose.

      Specified by:
        `isChunked` in interface `EntityDetails`
      Returns:
        the chunked transfer hint for this entity.

    - #### getTrailerNames

          public Set<String> getTrailerNames()

      Description copied from interface: `EntityDetails`
      Gets the preliminary declaration of trailing headers.
      Specified by:
        `getTrailerNames` in interface `EntityDetails`
      Returns:
        the preliminary declaration of trailing headers.

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