Constructs a new formatter with the specified file, charset, and locale.
file
| The file to use as the destination of this formatter. If the file exists then it will be truncated to zero size; otherwise, a new file will be created. The output will be written to the file and is buffered. | |
charset
| A charset | |
l
| The locale to apply during
formatting. If l is null then no localization
is applied. |
IOException
| if an I/O error occurs while opening or creating the file | |
SecurityException
| If a security manager is present and checkWrite(file.getPath()) denies
write access to the file | |
NullPointerException
| if file or charset is null. |
Diagram: Scanner, Formatter