Add DirUtils
This commit is contained in:
parent
173762e481
commit
dba1916de7
13
src/main/java/fr/pandacube/util/DirUtils.java
Normal file
13
src/main/java/fr/pandacube/util/DirUtils.java
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
package fr.pandacube.util;
|
||||||
|
|
||||||
|
import java.io.File;
|
||||||
|
|
||||||
|
public class DirUtils {
|
||||||
|
public static void delete(final File target) {
|
||||||
|
if (target.isDirectory())
|
||||||
|
for (final File child : target.listFiles())
|
||||||
|
delete(child);
|
||||||
|
|
||||||
|
target.delete();
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user