Skip to content

Instantly share code, notes, and snippets.

@hacksoldier
Created September 29, 2015 13:46
Show Gist options
  • Save hacksoldier/c6164cc1607b0327e0e0 to your computer and use it in GitHub Desktop.
Save hacksoldier/c6164cc1607b0327e0e0 to your computer and use it in GitHub Desktop.
private ArrayList<File> importFileFromPath(String forderPath)
{
ArrayList<File> files = new ArrayList<>();
File folder = new File(forderPath);
File[] listOfFile = folder.listFiles();
for (int i = 0; i < listOfFile.length; i++)
{
if (listOfFile[i].isFile())
{
files.add(listOfFile[i]);
}
}
return files;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment