Java tutorial
//package com.java2s; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import java.io.File; import java.util.List; public class Main { public static void initializeFiles(List<String> filePathNameList, List<Bitmap> imageBitMaps, int offset, int size) { for (int i = 0; i < (offset + size); i++) { if (new File(filePathNameList.get(i)).exists()) { imageBitMaps.add(BitmapFactory.decodeFile(filePathNameList.get(i))); } } } }