jrun.servlet.io
Class ByteWriter
java.lang.Object
|
+--java.io.Writer
|
+--jrun.servlet.io.ByteWriter
- public final class ByteWriter
- extends java.io.Writer
this writer convers chars to bytes simply by stripping off
the high-byte. compatible with ISO-8859-1 only.
Like OutputStreamWriter, we use an internal fixed-size byte array
to hold conversion output, before we write it to the underlying
stream.
Unlike OutputStreamWriter, we never hang onto those bytes before
writing them through. Thus we never have to worry about clearing
the internal buffer, since its contents are never used between
subsequent writes.
- Author:
- Edwin Smith
| Fields inherited from class java.io.Writer |
lock |
|
Constructor Summary |
ByteWriter(javax.servlet.ServletOutputStream out)
|
|
Method Summary |
void |
close()
|
void |
flush()
|
void |
write(char[] cbuf,
int off,
int len)
|
void |
write(int c)
|
void |
write(java.lang.String str)
|
void |
write(java.lang.String str,
int off,
int len)
|
| Methods inherited from class java.io.Writer |
write |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ByteWriter
public ByteWriter(javax.servlet.ServletOutputStream out)
write
public void write(int c)
throws java.io.IOException
- Overrides:
write in class java.io.Writer
write
public void write(char[] cbuf,
int off,
int len)
throws java.io.IOException
- Overrides:
write in class java.io.Writer
write
public void write(java.lang.String str)
throws java.io.IOException
- Overrides:
write in class java.io.Writer
write
public void write(java.lang.String str,
int off,
int len)
throws java.io.IOException
- Overrides:
write in class java.io.Writer
flush
public void flush()
throws java.io.IOException
- Overrides:
flush in class java.io.Writer
close
public void close()
throws java.io.IOException
- Overrides:
close in class java.io.Writer
Copyright � 2002 Macromedia Corporation. All Rights Reserved.