Java Utililty Methods File Move nui

List of utility methods to do File Move nui

Description

The list of methods to do File Move nui are organized into topic(s).

Method

voidmoveFile(String source, String target)
move File
copyFile(source, target);
deleteFile(source);
booleanmoveFile(String sourceFile, String destFile)
Moves a file.
java.io.File source = new java.io.File(sourceFile);
java.io.File dest = new java.io.File(destFile);
try {
    copyFile(source, dest);
    source.delete();
    return true;
} catch (IOException e) {
    e.printStackTrace();
...
booleanmoveFiles(File src, String newSrc, File dest)
Moves the source file to the destination file (similar to #copyFiles(File,File) but with deletion)
boolean r = false;
if (!dest.exists()) {
    r = dest.mkdirs();
File[] files = src.listFiles();
if (files == null) {
    try {
        Files.move(src.toPath(), new File(dest, newSrc).toPath(), StandardCopyOption.REPLACE_EXISTING);
...
voidmover(String file, String caminhoNovo)
mover
File arquivo = new File(file);
File caminhoNovoFile = new File(caminhoNovo + arquivo);
try {
    Files.move(arquivo.toPath(), caminhoNovoFile.toPath());
} catch (Exception e) {