I\'m using FileWriter to write to a file and noticed that even after I have deleted the file (out of process) the FileWriter does not throw any exception.
On Windows, you'd typically not be able to delete an open file.
On Unix, deleting an open file and continuing to write into it (or read from it) is perfectly acceptable. Once you delete the file, it will no longer have a directory entry. However, its contents will continue to exist on disk until the file is closed. Once all open handles that refer to the file get closed, the OS will automatically reclaim the disk space.