public synchronized void deleteAtExit ( FileNode node ) { if ( delete == null ) { // already exiting tryDelete ( node ) ; } else { delete . add ( node ) ; } }
Use this instead of File . deleteAtExist because it can delete none - empty directories