Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.mortbay.http.ajp
Class AJP13OutputStream  view AJP13OutputStream download AJP13OutputStream.java

java.lang.Object
  extended byjava.io.OutputStream
      extended byorg.mortbay.util.ByteBufferOutputStream
          extended byorg.mortbay.http.BufferedOutputStream
              extended byorg.mortbay.http.ajp.AJP13OutputStream
All Implemented Interfaces:
org.mortbay.http.HttpMessage.HeaderWriter

public class AJP13OutputStream
extends org.mortbay.http.BufferedOutputStream

OutputStream for AJP13 protocol.

Version:
$Revision: 1.10 $

Field Summary
private  AJP13ResponsePacket _ajpResponse
           
private  boolean _complete
           
private  boolean _completed
           
private  AJP13ResponsePacket _packet
           
private  boolean _persistent
           
private static org.apache.commons.logging.Log log
           
 
Fields inherited from class org.mortbay.http.BufferedOutputStream
_httpMessageWriter, _out
 
Fields inherited from class org.mortbay.util.ByteBufferOutputStream
_buf
 
Constructor Summary
(package private) AJP13OutputStream(java.io.OutputStream out, int bufferSize)
           
 
Method Summary
protected  void bypassWrite(byte[] b, int offset, int length)
           
 void close()
          This method closes the stream.
 void destroy()
           
 void end()
           
 void flush()
          This implementation calls the commitObserver on the first flush since construction or reset.
 void resetStream()
           
protected  void wrapBuffer()
          Wrap Buffer.
 void write(AJP13Packet packet)
           
 void writeHeader(org.mortbay.http.HttpMessage httpMessage)
           
 void writeTo(java.io.OutputStream out)
           
 
Methods inherited from class org.mortbay.http.BufferedOutputStream
getBypassBuffer, getCommitObserver, getOutputStream, isCommitted, setBypassBuffer, setCommitObserver, write, write
 
Methods inherited from class org.mortbay.util.ByteBufferOutputStream
bufferSize, capacity, ensureCapacity, ensureReserve, ensureSize, ensureSize, ensureSpareCapacity, isFixed, postReserve, postwrite, preReserve, prewrite, prewrite, prewrite, reset, setFixed, size, spareCapacity, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

private static org.apache.commons.logging.Log log

_packet

private AJP13ResponsePacket _packet

_complete

private boolean _complete

_completed

private boolean _completed

_persistent

private boolean _persistent

_ajpResponse

private AJP13ResponsePacket _ajpResponse
Constructor Detail

AJP13OutputStream

AJP13OutputStream(java.io.OutputStream out,
                  int bufferSize)
Method Detail

writeHeader

public void writeHeader(org.mortbay.http.HttpMessage httpMessage)
                 throws java.io.IOException

write

public void write(AJP13Packet packet)
           throws java.io.IOException

flush

public void flush()
           throws java.io.IOException
Description copied from class: org.mortbay.http.BufferedOutputStream
This implementation calls the commitObserver on the first flush since construction or reset.


close

public void close()
           throws java.io.IOException
Description copied from class: java.io.OutputStream
This method closes the stream. Any internal or native resources associated with this stream are freed. Any subsequent attempt to access the stream might throw an exception.

This method in this class does nothing.


resetStream

public void resetStream()

destroy

public void destroy()

end

public void end()
         throws java.io.IOException

wrapBuffer

protected void wrapBuffer()
                   throws java.io.IOException
Description copied from class: org.mortbay.http.BufferedOutputStream
Wrap Buffer. Called by flush() to allow the data in the buffer to be pre and post written for any protocol wrapping. The default implementation does nothing.


bypassWrite

protected void bypassWrite(byte[] b,
                           int offset,
                           int length)
                    throws java.io.IOException

writeTo

public void writeTo(java.io.OutputStream out)
             throws java.io.IOException