org.apache.hc.client5.http.impl.cache

## Class CachingHttpAsyncClients

- java.lang.Object
- - org.apache.hc.client5.http.impl.cache.CachingHttpAsyncClients

-     public final class CachingHttpAsyncClients
      extends Object

  Factory methods for `CloseableHttpAsyncClient` instances capable of client-side caching.
  Since:
    5.0

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static CloseableHttpAsyncClient` | `createFileBound(File cacheDir)` Creates `CloseableHttpAsyncClient` instance that uses a file system bound response cache.
    `static CloseableHttpAsyncClient` | `createHttp2FileBound(File cacheDir)` Creates HTTP/2 `CloseableHttpAsyncClient` instance that uses a file system bound response cache.
    `static CloseableHttpAsyncClient` | `createHttp2MemoryBound()` Creates HTTP/2 `CloseableHttpAsyncClient` instance that uses a memory bound response cache.
    `static CloseableHttpAsyncClient` | `createMemoryBound()` Creates `CloseableHttpAsyncClient` instance that uses a memory bound response cache.
    `static CachingHttpAsyncClientBuilder` | `custom()` Creates builder object for construction of custom `CloseableHttpAsyncClient` instances.
    `static CachingH2AsyncClientBuilder` | `customHttp2()` Creates builder object for construction of custom HTTP/2 `CloseableHttpAsyncClient` instances.

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

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

- - ### Method Detail

    - #### custom

          public static CachingHttpAsyncClientBuilder custom()

      Creates builder object for construction of custom `CloseableHttpAsyncClient` instances.

    - #### createMemoryBound

          public static CloseableHttpAsyncClient createMemoryBound()

      Creates `CloseableHttpAsyncClient` instance that uses a memory bound response cache.

    - #### createFileBound

          public static CloseableHttpAsyncClient createFileBound(File cacheDir)

      Creates `CloseableHttpAsyncClient` instance that uses a file system bound response cache.
      Parameters:
        `cacheDir` - location of response cache.

    - #### customHttp2

          public static CachingH2AsyncClientBuilder customHttp2()

      Creates builder object for construction of custom HTTP/2 `CloseableHttpAsyncClient` instances.

    - #### createHttp2MemoryBound

          public static CloseableHttpAsyncClient createHttp2MemoryBound()

      Creates HTTP/2 `CloseableHttpAsyncClient` instance that uses a memory bound response cache.

    - #### createHttp2FileBound

          public static CloseableHttpAsyncClient createHttp2FileBound(File cacheDir)

      Creates HTTP/2 `CloseableHttpAsyncClient` instance that uses a file system bound response cache.
      Parameters:
        `cacheDir` - location of response cache.

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