download

fun download(context: Context, remoteImage: RemoteImage, targetView: View? = null): LiveData<Drawable>

A function to get the Drawable from the provided remoteImage. The optional targetView is used to determine the expected Drawable size which fits the targetView.

Returns a LiveData that holds:

NOTE: It is the client's responsibility to make sure the RemoteImage.uri is secure and trusted.


fun download(context: Context, uri: Uri, placeholder: Drawable? = null, fallback: Drawable? = null, targetView: View? = null): LiveData<Drawable>

A function to get the Drawable from the provided uri. The optional targetView is used to determine the expected Drawable size which fits the targetView.

Returns a LiveData that holds:

NOTE: It is the client's responsibility to make sure the uri is secure and trusted.