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

## Class NoopCacheEntrySerializer

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

- All Implemented Interfaces:
    HttpCacheEntrySerializer<HttpCacheStorageEntry>

      @Contract(threading=STATELESS)
      public class NoopCacheEntrySerializer
      extends Object
      implements HttpCacheEntrySerializer<HttpCacheStorageEntry>

  `HttpCacheEntrySerializer` that uses `HttpCacheStorageEntry` as its cache content representation.
  Since:
    5.0

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static NoopCacheEntrySerializer` | `INSTANCE`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `NoopCacheEntrySerializer()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `HttpCacheStorageEntry` | `deserialize(HttpCacheStorageEntry cacheEntry)` Deserializes a cache entry from its serialized representation.
    `HttpCacheStorageEntry` | `serialize(HttpCacheStorageEntry cacheEntry)` Serializes the given entry.

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

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

- - ### Field Detail

    - #### INSTANCE

          public static final NoopCacheEntrySerializer INSTANCE

  - ### Constructor Detail

    - #### NoopCacheEntrySerializer

          public NoopCacheEntrySerializer()

  - ### Method Detail

    - #### serialize

          public HttpCacheStorageEntry serialize(HttpCacheStorageEntry cacheEntry)
                                          throws ResourceIOException

      Description copied from interface: `HttpCacheEntrySerializer`
      Serializes the given entry.
      Specified by:
        `serialize` in interface `HttpCacheEntrySerializer<HttpCacheStorageEntry>`
      Parameters:
        `cacheEntry` - cache entry
      Returns:
        serialized representation of the cache entry
      Throws:
        `ResourceIOException`

    - #### deserialize

          public HttpCacheStorageEntry deserialize(HttpCacheStorageEntry cacheEntry)
                                            throws ResourceIOException

      Description copied from interface: `HttpCacheEntrySerializer`
      Deserializes a cache entry from its serialized representation.
      Specified by:
        `deserialize` in interface `HttpCacheEntrySerializer<HttpCacheStorageEntry>`
      Parameters:
        `cacheEntry` - serialized representation of the cache entry
      Returns:
        cache entry
      Throws:
        `ResourceIOException`

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