Interface Key

All Known Subinterfaces:
Transformation<T>
All Known Implementing Classes:
AndroidResourceSignature, BitmapDrawableTransformation, BitmapTransformation, CenterCrop, CenterInside, CircleCrop, DrawableTransformation, EmptySignature, FitCenter, GifDrawableTransformation, GlideUrl, GranularRoundedCorners, MediaStoreSignature, MultiTransformation, ObjectKey, Options, Rotate, RoundedCorners, UnitTransformation

public interface Key
An interface that uniquely identifies some put of data. Implementations must implement Object.equals(Object) and Object.hashCode(). Implementations are generally expected to add all uniquely identifying information used in in Object.equals(Object)} and Object.hashCode()} to the given MessageDigest in updateDiskCacheKey(java.security.MessageDigest)}, although this requirement is not as strict for partial cache key signatures.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final Charset
     
    static final String
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    For caching to work correctly, implementations must implement this method and hashCode().
    int
    For caching to work correctly, implementations must implement this method and equals(Object).
    void
    Adds all uniquely identifying information to the given digest.
  • Field Details

  • Method Details

    • updateDiskCacheKey

      void updateDiskCacheKey(@NonNull MessageDigest messageDigest)
      Adds all uniquely identifying information to the given digest.

      Note - Using MessageDigest.reset() inside of this method will result in undefined behavior.

    • equals

      boolean equals(Object o)
      For caching to work correctly, implementations must implement this method and hashCode().
      Overrides:
      equals in class Object
    • hashCode

      int hashCode()
      For caching to work correctly, implementations must implement this method and equals(Object).
      Overrides:
      hashCode in class Object