You can rap your Writer with a BufferedWriter for better performance. BufferedWriter has the following constructors:
public BufferedWriter (Writer writer) public BufferedWriter (Writer writer, in bufferSize)
Wrap FileWriter in a BufferedWriter:
FileWriter fw = new FileWriter(aFile); BufferedWriter bw = new BufferedWriter (fw);
Wrap the Writer to a PrintWriter.
FileWriter fw = new FileWriter (aFile); PrintWriter pw = new PrintWriter (new BufferedWriter(fw));