-
Bug
-
Resolution: Duplicate
-
P3
-
None
-
1.0
-
sparc
-
generic
From ###@###.### Mon Mar 18 15:55:00 1996
Date: Mon, 18 Mar 1996 15:52:24 -0800
From: ###@###.### (Arthur van Hoff)
To: pavani@Eng
Subject: File.delete()
Mime-Version: 1.0
Hi Pavani,
It is currently impossible to delete directories from Java.
The delete() method in java.io.File does not delete the directory
when the File object refers to a directory (even when it is empty).
This leaves no alternative way to delete a directory.
Can you please file a bug against this? It would really help us
if this gets fixed. I've attached a test program. Thanks!
Have fun,
Arthur van Hoff
-----Test--------------------
import java.io.File;
public class Test {
public static void main(String argv[]) {
File f = new File(argv[0]);
System.out.println("mkdir = " + f.mkdir());
System.out.println("delete = " + f.delete());
}
}
Date: Mon, 18 Mar 1996 15:52:24 -0800
From: ###@###.### (Arthur van Hoff)
To: pavani@Eng
Subject: File.delete()
Mime-Version: 1.0
Hi Pavani,
It is currently impossible to delete directories from Java.
The delete() method in java.io.File does not delete the directory
when the File object refers to a directory (even when it is empty).
This leaves no alternative way to delete a directory.
Can you please file a bug against this? It would really help us
if this gets fixed. I've attached a test program. Thanks!
Have fun,
Arthur van Hoff
-----Test--------------------
import java.io.File;
public class Test {
public static void main(String argv[]) {
File f = new File(argv[0]);
System.out.println("mkdir = " + f.mkdir());
System.out.println("delete = " + f.delete());
}
}
- duplicates
-
JDK-1231492 FIle.delete() will not remove directories
- Closed