Reader
public
abstract
class
Reader
extends Object
implements
Closeable,
Readable
| java.lang.Object | |
| ↳ | java.io.Reader |
Abstract class for reading character streams. The only methods that a subclass must implement are read(char[], int, int) and close(). Most subclasses, however, will override some of the methods defined here in order to provide higher efficiency, additional functionality, or both.
See also:
Summary
Fields | |
|---|---|
protected
Object |
lock
The object used to synchronize operations on this stream. |
Protected constructors | |
|---|---|
Reader()
Creates a new character-stream reader whose critical sections will synchronize on the reader itself. |
|
Reader(Object lock)
Creates a new character-stream reader whose critical sections will synchronize on the given object. |
|
Public methods | |
|---|---|
abstract
void
|
close()
Closes the stream and releases any system resources associated with it. |
void
|
mark(int read |