Here you can find the source of delete(String path)
Parameter | Description |
---|---|
path | the File path. |
public static boolean delete(String path)
//package com.java2s; import java.io.File; public class Main { /**//from w w w.j av a 2 s . c om * Attempts to delete the File with the given path. * * @param path the File path. * @return true if the operation succeeded, false otherwise. */ public static boolean delete(String path) { return new File(path).delete(); } }