You can cache images either on disk or in memory.
By default, images are cached in memory using Glide.
It's also good to know that Glide places all image resources in the cache cache by default. Thus, a special call to .skipMemoryCache (false) is not required.
If you want to enable cache on disk, you can use one of the following
DiskCacheStrategy.SOURCE caches only the original full resolution image.DiskCacheStrategy.RESULT only caches the final image, after decreasing the resolution (and possibly conversion)DiskCacheStrategy.ALL caches all versions of the image (default behavior)
Using:
Glide .with( context ) .load( url ) .diskCacheStrategy( DiskCacheStrategy.ALL ) .into( imageViewInternet );
source share