com.github.ignition.support.images.remote
Class RemoteImageLoaderJob

java.lang.Object
  extended by com.github.ignition.support.images.remote.RemoteImageLoaderJob
All Implemented Interfaces:
Runnable

public class RemoteImageLoaderJob
extends Object
implements Runnable


Constructor Summary
RemoteImageLoaderJob(String imageUrl, RemoteImageLoaderHandler handler, ImageCache imageCache, int numRetries, int defaultBufferSize)
           
 
Method Summary
protected  android.graphics.Bitmap downloadImage()
           
protected  void notifyImageLoaded(String url, android.graphics.Bitmap bitmap)
           
protected  byte[] retrieveImageData()
           
 void run()
          The job method run on a worker thread.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RemoteImageLoaderJob

public RemoteImageLoaderJob(String imageUrl,
                            RemoteImageLoaderHandler handler,
                            ImageCache imageCache,
                            int numRetries,
                            int defaultBufferSize)
Method Detail

run

public void run()
The job method run on a worker thread. It will first query the image cache, and on a miss, download the image from the Web.

Specified by:
run in interface Runnable

downloadImage

protected android.graphics.Bitmap downloadImage()

retrieveImageData

protected byte[] retrieveImageData()
                            throws IOException
Throws:
IOException

notifyImageLoaded

protected void notifyImageLoaded(String url,
                                 android.graphics.Bitmap bitmap)


Copyright © 2012. All Rights Reserved.