Java crea directorio si no existe
String path = ...
File pathAsFile = new File(path);
if (!Files.exists(Paths.get(path))) {
pathAsFile.mkdir();
}
No Name Pro
String path = ...
File pathAsFile = new File(path);
if (!Files.exists(Paths.get(path))) {
pathAsFile.mkdir();
}
String path = "testpath/hello";
File folder = new File(path);
if (!folder.exists()) {
folder.mkdir();
}