Android File Delete deleteFile(File f)

Here you can find the source of deleteFile(File f)

Description

delete File

Declaration

public static void deleteFile(File f) 

Method Source Code

//package com.java2s;
import java.io.File;

public class Main {
    public static void deleteFile(File f) {
        if (!f.exists())
            return;
        boolean deleted = f.delete();
        if (!deleted)
            throw new IllegalStateException("Could not delete file " + f);
    }// ww w  .  j a v  a 2s.co  m
}

Related

  1. deleteDir(File dir)
  2. deleteDir(File spec)
  3. deleteDirContent(File d)
  4. deleteFile(File f)
  5. deleteFile(File f)
  6. deleteFile(File file)
  7. deleteFile(File file)
  8. deleteFile(File file)
  9. deleteFile(File file)