Java File Path Delete deleteFileWithoutException(final String path)

Here you can find the source of deleteFileWithoutException(final String path)

Description

delete File Without Exception

License

Open Source License

Declaration

public static void deleteFileWithoutException(final String path) 

Method Source Code

//package com.java2s;
// Licensed under the MIT license. See License.txt in the repository root.

import java.io.File;

public class Main {
    public static void deleteFileWithoutException(final String path) {
        try {/*ww w.  j av  a2 s .  c  o  m*/
            new File(path).delete();
        } catch (final Throwable t) {
        }
    }
}

Related

  1. deleteFilesInDirectory(String pathname)
  2. deleteFilesinPath(File pBaseDir, String pFileName)
  3. deleteFilesRecursive(final File path)
  4. deleteFileSystemDirectory(String dirPath)
  5. deleteFileSystemDirectory(String dirPath)
  6. deleteFileWithSuffix(String path, String suffix)
  7. deleteFolder(File path)
  8. deleteFolder(File path)
  9. deleteFolder(String filePath)