Here you can find the source of getFiles(String path)
public static File[] getFiles(String path)
//package com.java2s; //License from project: Open Source License import java.io.File; public class Main { public static File[] getFiles(String path) { File file = new File(path); if (file.exists()) { return file.listFiles(); }/* w ww .j av a 2 s . c o m*/ return null; } }