Android SDK - Image Download Module
Last updated: Aug 15th, 8:01am
The Image Download module of the SDK exposes the functionality related to retrieving images associated with various wallet artifacts, such as supported payment tenders, for display in the app.
Item | Description |
---|---|
UI Services | com.paydiant.android.ui.service.image.ImageDownloadService |
Core Services | com.paydiant.android.core.facade.ImageDowloadManagerFacade |
Set UI Package Image Download Listeners
Set an implementation of the applicable listener interfaces in the UI Service class to receive the callback methods returned by the Paydiant service in response to the methods invoked by the Image Download module of the SDK.
Item | Description |
---|---|
Set Preference Listener | void setImageDownloadListener(IImageDownloadListener listener); |
com.paydiant.android.ui.service.image.IImageDownloadListener
or an overridden instance of
com.paydiant.android.ui.service.image.ImageDownloadListenerAdapter
|
|Remove Listener|void removeListener();
Call from within the corresponding service class to remove the associated listener and set it to null.|
Download Images
Call this method to retrieve the set of images for the specified URLs relevant for the wallet.
Item | Description |
---|---|
UI Method | void loadImageList(List < URL > imageURLList); |
Parameters | imageURLList - The list of image URLs to be retrieved. |
Success | void onImageDownloadSuccess(Map < String, Bitmap > downloadImageMap); |
Parameters | downloadImageMap - The successful call returns a map of bitmap images for each of the URLs specified in the request. |
Failure | void onImageDownloadError(PaydiantException exception); The failure callback returns an instance of PaydiantException for the module including relevant error codes. |
Core Method | List< DownloadImageInfo > downloadImageList(List < DownloadImageInfo > downloadImageList); Returns aw output for the retrieval results or relevant exception. |
Errors
When retrieving the wallet images, the following error is applicable:
Error | Description |
---|---|
500 | An unknown error occurred internally in the server. |
Max Pool Size
Call this method to limit the pool size available to the application during download in order to avoid performance impact.
Item | Description |
---|---|
UI Method | void setMaxPoolSize(final int MAX_POOL_SIZE); |
Core Method | There is no Core implementation for this method |