| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objecttribble.io.LineToCharInputStream
public class LineToCharInputStream
Input stream which converts lines of text into single characters.
 This interface is used to implement a variant of a character input stream,
 which is capable of reading a single character at a time from an underlying
 text line input stream.  Such a stream can be used to read the underlying
 source text for a lexical analyzer (lexer), such as the LexerI
 interface.
LexerI, 
CharInputStreamI| Field Summary | |
|---|---|
| protected  LineInputStreamI | m_inText line input stream. | 
| protected  int | m_lenLength of the current text line. | 
| protected  int | m_nextiPosition of next character to read from the current text line. | 
| protected  DiagnosticOutputI | m_outDiagnostic output stream. | 
| protected  java.lang.String | m_textCurrent input text line. | 
| (package private) static java.lang.String | REVRevision information. | 
| Constructor Summary | |
|---|---|
| LineToCharInputStream()Default constructor. | |
| LineToCharInputStream(LineInputStreamI in)Constructor. | |
| LineToCharInputStream(java.io.Reader in)Constructor. | |
| Method Summary | |
|---|---|
|  void | close()Close the input stream. | 
|  int | readChar()Read the next character from the input stream. | 
|  void | setInput(LineInputStreamI in)Establish the text line input stream from which to read lines of text, from which individual characters are read. | 
|  void | setInput(java.io.Reader in)Establish the input stream from which to read characters. | 
|  void | setOutput(DiagnosticOutputI out)Establish the output stream to which diagnostic messages (warning and error messages) are written during parsing. | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
static final java.lang.String REV
protected LineInputStreamI m_in
protected DiagnosticOutputI m_out
protected java.lang.String m_text
protected int m_len
protected int m_nexti
| Constructor Detail | 
|---|
public LineToCharInputStream()
public LineToCharInputStream(LineInputStreamI in)
in - The text line input stream for this character stream.public LineToCharInputStream(java.io.Reader in)
in - The input stream for this character stream.| Method Detail | 
|---|
public void setOutput(DiagnosticOutputI out)
setOutput in interface DiagnosticWriterIout - The error output stream.public void setInput(LineInputStreamI in)
in - The text line input stream from which to read.public void setInput(java.io.Reader in)
setInput in interface CharInputStreamIin - The input stream from which to read characters.public void close()
close in interface CharInputStreamI
public int readChar()
             throws java.io.IOException
readChar in interface CharInputStreamIjava.io.IOException - Thrown if an I/O (read) error occurs.| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||