java.io.BufferedWriter (JDK 1.1)
This class applies buffering to a character output stream, improving output efficiency by coalescing many small write requests into a single larger request. You create a BufferedWriter by specifying some other character output stream to which it sends its buffered and coalesced output. (You can also specify a buffer size at this time, although the default size is usually satisfactory.) Typically you use this sort of buffering when you are using a FileWriter or OutputStreamWriter.
BufferedWriter defines the standard write(), flush(), and close() methods that all output streams define, but it also adds a newLine() method, which outputs the platform-dependent line separator (usually a newline character, a carriage return character, or both) to the stream.
BufferedWriter is the character-stream analog of BufferedOutputStream.
public classBufferedWriterextends Writer { //Public ConstructorspublicBufferedWriter(Writerout); publicBufferedWriter(Writerout, intsz); //Public Instance Methodspublic voidclose() throws IOException; //Defines Writerpublic voidflush() throws IOException; //Defines Writerpublic voidnewLine() throws IOException; public voidwrite(intc) throws IOException; //Overrides Writerpublic voidwrite(char[]cbuf, intoff, intlen) throws IOException; //Defines Writerpublic voidwrite(Strings, intoff, intlen) throws IOException; //Overrides Writer}
Hierarchy:
Object->Writer->BufferedWriter