This class is a character input stream that uses a String object as the source of the characters it returns. When you create a StringReader, you must specify the String that it is to read from.
StringReader defines the normal Reader methods, and supports mark() and reset(). If reset() is called before mark() has been called, the stream is reset to the beginning of the specified string.
StringReader is a character stream analog to StringBufferInputStream, which is deprecated in Java 1.1. StringReader is also similar to CharArrayReader.
public class StringReader extends Reader { // Public Constructor public StringReader(String s); // Public Instance Methods public void close(); // Defines Reader public void mark(int readAheadLimit) throws IOException; // Overrides Reader public boolean markSupported(); // Overrides Reader public int read() throws IOException; // Overrides Reader public int read(char[] cbuf, int off, int len) throws IOException; // Defines Reader public boolean ready(); // Overrides Reader public void reset() throws IOException; // Overrides Reader public long skip(long ns) throws IOException; // Overrides Reader }
Object->Reader->StringReader
This HTML Help has been published using the chm2web software. |