The Writer class is an abstract
class that is the superclass of all classes that represent output character
streams. Writer defines the
basic output methods that all character streams provide. A similar hierarchy
of classes, based around OutputStream,
deals with byte streams instead of character streams.

Writer is designed so that
write(intb)
and write(char[])
both call write(char[],int,int).
Thus, a subclass can simply override write(char[],int,int)
and all of the write methods
will work. Note that this is different from the design of OutputStream,
where the write(intb)
method is the catch-all method. The design of Writer
is cleaner and more efficient.

Some Writer subclasses may
implement buffering to increase efficiency. Writer
provides a method--flush()--that tells the Writer to write
any buffered output to the underlying device, which may be a disk drive
or a network.

The object used to synchronize operations on this Writer
object. For efficiency's sake, a particular implementation of a character
stream can choose to synchronize its operations on something other than
instances of itself. Thus, any subclass should synchronize on the lock
object, instead of using a synchronized
method or the this object.

This method writes a character containing the lowest sixteen bits of the
given integer value.

The implementation of this method in Writer
writes the character by calling write(cb,1)
where cb is a character array
that contains the given value in cb[0].
Although it is not strictly necessary, a subclass that wants to provide
efficient single-character writes should override this method.

This method writes len characters contained in the
given string starting at index off. The method
does this by creating an array of characters for the specified portion
of the string and then calling write(cb, 0,
cb.length) on the character array cb.

A subclass does not usually need to override this method, as it can override
write(char[],int,int)
and have it work automatically.