Package java.io
Class PrintWriter

Public Method flush

void flush()

Overrides:

_INSERT_METHOD_SIGNATURE_HERE_

Description:

This method flushes this stream.

Example

   File file = new File("testFile");
   String fileString = "Hello World";
   OutputStream fos = new FileOutputStream(file);
   PrintWriter pw = new PrintWriter(fos);
   ...
   pw.flush();

The example above flushes the stream.