Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- String contentPath = "c:\temp\data";
- String tmpContentPath = "c:\temp\data.TMP";
- if (Files.exists(Paths.get(tmpContentPath)) && Files.list(Paths.get(tmpContentPath)).count() > 0) {
- FileUtils.deleteDirectory(new File(contentPath));
- Files.move(Paths.get(tmpContentPath), Paths.get(contentPath), java.nio.file.StandardCopyOption.REPLACE_EXISTING);
- }
Add Comment
Please, Sign In to add comment