java.lang.Object
de.haumacher.msgbuf.io.StringW
- All Implemented Interfaces:
Writer
-
Constructor Details
-
StringW
public StringW()
-
-
Method Details
-
write
public void write(char ch) Description copied from interface:WriterWrites a single character. The character to be written is contained in the 16 low-order bits of the given integer value; the 16 high-order bits are ignored.Subclasses that intend to support efficient single-character output should override this method.
-
write
Description copied from interface:WriterWrites a string. -
write
Description copied from interface:WriterWrites a portion of a string.- Specified by:
writein interfaceWriter- Parameters:
str- A Stringstart- Offset from which to start writing characterslength- Number of characters to write- Throws:
IOException- If an I/O error occurs
-
flush
public void flush()Description copied from interface:WriterFlushes the stream. If the stream has saved any characters from the various write() methods in a buffer, write them immediately to their intended destination. Then, if that destination is another character or byte stream, flush it. Thus one flush() invocation will flush all the buffers in a chain of Writers and OutputStreams. -
close
public void close()Description copied from interface:WriterCloses the stream, flushing it first. Once the stream has been closed, further write() or flush() invocations will cause an IOException to be thrown. Closing a previously closed stream has no effect. -
toString
-