Target - Type of the target that is used by Task implementation to load requested image.Transformation - Type of the transformation that can be applied to the loaded image.public static interface ImageLoader.Task<Target,Transformation>
ImageLoader.load(Task),
ImageLoader.load(Task, Callback),
ImageLoader.remove(Task)| Modifier and Type | Field and Description |
|---|---|
static int |
NO_RESOURCE_ID
Constant determining that no resource id has been specified.
|
| Modifier and Type | Method and Description |
|---|---|
ImageLoader.Task<Target,Transformation> |
doNotAnimate(boolean animate)
Specifies a boolean flag determining whether to animate attaching of image bitmap to the
associated image view or not.
|
ImageLoader.Task<Target,Transformation> |
error(Drawable error)
Specifies a drawable to be set to the associated image view when image loading process
fails due to some error.
|
ImageLoader.Task<Target,Transformation> |
error(int resId)
Same as
error(Drawable) for resource id. |
ImageLoader.Task<Target,Transformation> |
placeholder(Drawable placeholder)
Specifies a drawable to be set to the associated image view while image loading process
is finished.
|
ImageLoader.Task<Target,Transformation> |
placeholder(int resId)
Same as
placeholder(Drawable) for resource id. |
Target |
target()
Returns the target referring to the image bitmap to be loaded.
|
ImageLoader.Task<Target,Transformation> |
target(Target target)
Specifies a target that refers to the image bitmap stored whether online on a remote
server or offline within this Android device's cache (memory, disk) to be loaded via
this task.
|
ImageLoader.Task<Target,Transformation> |
transform(Transformation transformation)
Specifies a transformation to be applied to the loaded bitmap before it is set to the
associated image view.
|
ImageView |
view()
Returns the image view specified for this task.
|
ImageLoader.Task<Target,Transformation> |
view(ImageView view)
Specifies an image view to which should be attached image bitmap loaded via this task.
|
static final int NO_RESOURCE_ID
ImageLoader.Task<Target,Transformation> target(@NonNull Target target)
target - The desired target.target(),
placeholder(Drawable),
error(Drawable)@NonNull Target target()
target(Object)ImageLoader.Task<Target,Transformation> placeholder(@DrawableRes int resId)
placeholder(Drawable) for resource id.resId - Resource id of the desired placeholder drawable. May be NO_RESOURCE_ID
to not use any.ImageLoader.Task<Target,Transformation> placeholder(@Nullable Drawable placeholder)
placeholder - The desired placeholder drawable. May be null to not use any.error(Drawable)ImageLoader.Task<Target,Transformation> error(@DrawableRes int resId)
error(Drawable) for resource id.resId - Resource id of the desired error drawable. May be NO_RESOURCE_ID
to not use any.ImageLoader.Task<Target,Transformation> error(@Nullable Drawable error)
error - The desired error drawable. May be null to not use any.placeholder(Drawable)ImageLoader.Task<Target,Transformation> transform(@Nullable Transformation transformation)
transformation - The desired transformation. May be null to not use any.ImageLoader.Task<Target,Transformation> doNotAnimate(boolean animate)
animate - True to animate bitmap attaching, false otherwise.ImageLoader.Task<Target,Transformation> view(@NonNull ImageView view)
view - The desired image view.view(),
transform(Object)@Nullable ImageView view()
view(ImageView)