Here you can find the source of getFileListInFolder(String path)
public static File[] getFileListInFolder(String path)
//package com.java2s; //License from project: Open Source License import java.io.*; import java.util.ArrayList; public class Main { public static File[] getFileListInFolder(String path) { ArrayList<File> results = new ArrayList<>(); File[] files = new File(path).listFiles(); for (File file : files) { if (file.isFile()) { results.add(file);/*ww w . j a v a2s .co m*/ } } return results.toArray(new File[0]); } public static double[][] add(double[][] a, double[][] b) { double[][] d = new double[a.length][a[0].length]; if (isIdenticalMatrix(a, b)) { for (int i = 0; i < a.length; i++) { for (int j = 0; j < a[0].length; j++) { d[i][j] = a[i][j] + b[i][j]; } } } else { } return d; } private static boolean isIdenticalMatrix(double[][] a, double[][] b) { if (a.length == b.length && a[0].length == b[0].length) { return true; } else { return false; } } }