private void copyDirectoryAndBackUpOldFiles(File source, File target) {
        for (File f : source.listFiles()) {
            if (f.isFile()) {
                try {
                    copyFileAndBackUpOldCopy(f, new File(target, f.getName()));
                } catch (IOException ex) {
                    System.out.println("Failed to copy file '" + f.getName() + "'.");
                    ex.printStackTrace(System.out);
                }
            } else if (f.isDirectory()) {
                copyDirectoryAndBackUpOldFiles(f, new File(target, f.getName()));
            }
        }
    }