I am using the following method
Bitmap bitmap = Picasso.with(ListofCardsActivity.this)
.load(overLayUrl).get();
for downloading and get the image from the web url.
Does this method download the image from the url every time, even if it is downloaded already?
What I want is that once the image is downloaded, then from the next time onwards, I should get the image from the cache, no need to download.
If we have the method like the above requirement. please let me know
Does this method download the image from the url every time, even if it is downloaded already?
Not if it is cached.
The Picasso
instance you get back with with()
is pre-configured to have a memory cache and a disk cache.
Depending on how much you are downloading, you may run out of cache space. And I would hope that Picasso uses stuff like ETag
and If-Modified-Since
to re-download the image if the image has changed on the server, though I have not examined their code to see if they do, as that behavior is not documented.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With