***************************** Usage example ***********************
The following code shows how to retrieve an image and display it:
TextView tv = new TextView(this);
try {
FileDownloader downloader = new FileDownloader(this.getFilesDir());
String url = "http://i0.kym-cdn.com/entries/icons/original/000/003/619/Untitled-1.jpg";
File path = downloader.get(url);
BitmapFactory.Options options = new BitmapFactory.Options();
options.inSampleSize = 1;
final Bitmap b = BitmapFactory.decodeFile(path.getPath(), options);
ImageView imagenDescargada = new ImageView(this);
imagenDescargada.setImageBitmap(b);
setContentView(imagenDescargada);
} catch (MalformedURLException e){
tv.setText("URL incorrecta");
setContentView(tv);
} catch (FileNotFoundException e){
tv.setText("la URL no existe");
setContentView(tv);
} catch (IOException e) {*
tv.setText("error en la conexión");
setContentView(tv);
}