lamdba 一行文 Arrays.stream(new File("/folder/path").listFiles()).forEach(File::delete); https://stackoverflow.com/questions/13195797/delete-all-files-in-directory-but-not-directory-one-liner-solution