public static void moveFile ( File src , File dest ) throws IOException { copyFile ( src , dest ) ; if ( ! delete ( src ) ) { throw new IOException ( "Failed to delete the src file '" + src + "' after copying." ) ; } }
Moves a file from src to dest . This method is equals to copy - > delete .