Module methanol

Enum Class CacheAwareResponse.CacheStatus

java.lang.Object
java.lang.Enum<CacheAwareResponse.CacheStatus>
com.github.mizosoft.methanol.CacheAwareResponse.CacheStatus
All Implemented Interfaces:
Serializable, Comparable<CacheAwareResponse.CacheStatus>, Constable
Enclosing interface:
CacheAwareResponse<T>

public static enum CacheAwareResponse.CacheStatus extends Enum<CacheAwareResponse.CacheStatus>
The status of an attempt to retrieve an HTTP response from cache.
  • Enum Constant Details

    • MISS

      public static final CacheAwareResponse.CacheStatus MISS
      Either the cache lacked a matching response or the matching response was stale but failed validation with the server and thus had to be re-downloaded.
    • HIT

      public static final CacheAwareResponse.CacheStatus HIT
      The response was entirely constructed from cache and no network was used.
    • CONDITIONAL_HIT

      public static final CacheAwareResponse.CacheStatus CONDITIONAL_HIT
      The response was constructed from cache but a conditional GET had to be made to validate it with the server.
    • UNSATISFIABLE

      public static final CacheAwareResponse.CacheStatus UNSATISFIABLE
      The response was generated by the cache to serve an unsatisfiable request that prohibited network use despite being necessary to serve a valid response. The resulted response code is normally Gateway Timeout.
  • Method Details

    • values

      public static CacheAwareResponse.CacheStatus[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static CacheAwareResponse.CacheStatus valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null