org.mule.impl.model.streaming
Class DeferredOutputStream

java.lang.Object
  extended byjava.io.OutputStream
      extended byorg.mule.impl.model.streaming.DeferredOutputStream

public class DeferredOutputStream
extends OutputStream

This outputStream allows a stream to be choosen after this has been created. It is used by Mule when using streaming to pass to the Streaming component. The actual output stream is choosen at the point where the first byte is written. At this point an outbound router can be choosen and vales set on the event context can affect which stream is choosen.


Field Summary
protected  Log logger
           
 
Constructor Summary
DeferredOutputStream(UMOEventContext event)
           
DeferredOutputStream(UMOEventContext event, int buffer)
           
 
Method Summary
 void close()
           
 void flush()
           
 int getBuffer()
           
protected  OutputStream getOutputStream()
           
protected  OutputStream getOutputStreamFromRouter()
           
 void setBuffer(int buffer)
           
 void write(int b)
           
 
Methods inherited from class java.io.OutputStream
write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected final Log logger
Constructor Detail

DeferredOutputStream

public DeferredOutputStream(UMOEventContext event)

DeferredOutputStream

public DeferredOutputStream(UMOEventContext event,
                            int buffer)
Method Detail

write

public void write(int b)
           throws IOException
Throws:
IOException

flush

public void flush()
           throws IOException
Throws:
IOException

close

public void close()
           throws IOException
Throws:
IOException

getOutputStream

protected OutputStream getOutputStream()
                                throws IOException
Throws:
IOException

getBuffer

public int getBuffer()

setBuffer

public void setBuffer(int buffer)

getOutputStreamFromRouter

protected OutputStream getOutputStreamFromRouter()
                                          throws IOException
Throws:
IOException


Copyright © 2003-2008 MuleSource, Inc.. All Rights Reserved.