|
Can a file be written to after it has been closed? A good answer might be:No. |
FileWriter ConstructorsHere is an excerpt from the example program. The constructor for FileWriter is passed a String which contains the name for the file. When the FileWriter is constructed, a new disk file is created in the current directory and given that name, replacing any previous file with the same name. The file will be named "reaper.txt" and the stream that writes to it is writer.
The two constructors that interest us are:
If append is true, the second constructor will open an existing file will for writing without destroying its contents. If the file does not exist, it will be created. |
QUESTION 8:Click Here after you have answered the question |