com.caucho.server.http
Class ServletOutputStreamImpl

java.lang.Object
  extended by java.io.OutputStream
      extended by javax.servlet.ServletOutputStream
          extended by com.caucho.server.http.ServletOutputStreamImpl
All Implemented Interfaces:
java.io.Closeable, java.io.Flushable

public class ServletOutputStreamImpl
extends ServletOutputStream

Implementation of the ServletOutputStream.


Constructor Summary
ServletOutputStreamImpl()
           
 
Method Summary
 void close()
           
 void flush()
           
 void init(java.io.OutputStream out)
          Initialize with the current response stream.
 void print(java.lang.String s)
          Prints a string to the stream.
 java.lang.String toString()
           
 void write(byte[] buf, int offset, int len)
          Writes a byte buffer to the output stream.
 void write(int b)
          Writes a byte to the output stream.
 
Methods inherited from class javax.servlet.ServletOutputStream
print, print, print, print, print, print, println, println, println, println, println, println, println, println
 
Methods inherited from class java.io.OutputStream
write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ServletOutputStreamImpl

public ServletOutputStreamImpl()
Method Detail

init

public void init(java.io.OutputStream out)
Initialize with the current response stream.


write

public final void write(int b)
                 throws java.io.IOException
Writes a byte to the output stream.

Specified by:
write in class java.io.OutputStream
Throws:
java.io.IOException

write

public final void write(byte[] buf,
                        int offset,
                        int len)
                 throws java.io.IOException
Writes a byte buffer to the output stream.

Overrides:
write in class java.io.OutputStream
Throws:
java.io.IOException

print

public void print(java.lang.String s)
           throws java.io.IOException
Prints a string to the stream. Note, this method does not properly handle character encoding.

Overrides:
print in class ServletOutputStream
Parameters:
s - the string to write.
Throws:
java.io.IOException

flush

public final void flush()
                 throws java.io.IOException
Specified by:
flush in interface java.io.Flushable
Overrides:
flush in class java.io.OutputStream
Throws:
java.io.IOException

close

public final void close()
                 throws java.io.IOException
Specified by:
close in interface java.io.Closeable
Overrides:
close in class java.io.OutputStream
Throws:
java.io.IOException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object