xsul.http_common
Class NotifyCloseInputStream

java.lang.Object
  extended byjava.io.InputStream
      extended byxsul.http_common.NotifyCloseInputStream

public class NotifyCloseInputStream
extends java.io.InputStream

This is specialization of input stream that will notify observer when close() is called but will NOT close underlying stream!

Version:
$Revision: 1.5 $
Author:
Aleksander Slominski

Constructor Summary
NotifyCloseInputStream(java.io.InputStream input, java.util.Observer observer)
           
 
Method Summary
 void close()
           
 int read()
           
 int read(byte[] buf, int offset, int length)
           
 java.lang.String toString()
           
 
Methods inherited from class java.io.InputStream
available, mark, markSupported, read, reset, skip
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

NotifyCloseInputStream

public NotifyCloseInputStream(java.io.InputStream input,
                              java.util.Observer observer)
                       throws java.lang.IllegalArgumentException
Method Detail

read

public int read()
         throws java.io.IOException
Throws:
java.io.IOException

read

public int read(byte[] buf,
                int offset,
                int length)
         throws java.io.IOException
Throws:
java.io.IOException

close

public void close()
           throws java.io.IOException
Throws:
java.io.IOException

toString

public java.lang.String toString()


IU Extreme! Lab (http://www.extreme.indiana.edu)