de.netseeker.ejoe.io
Class UncloseableInputStream

java.lang.Object
  extended by java.io.InputStream
      extended by java.io.FilterInputStream
          extended by de.netseeker.ejoe.io.UncloseableInputStream
All Implemented Interfaces:
java.io.Closeable

public class UncloseableInputStream
extends java.io.FilterInputStream

Simple buffered input stream wrapper which overwrites #close to prevent some and is used when input streams are handed over to (de)serialize adapters to prevent some parsers, eg. Xerces, to close our socket input streams automatically.

Since:
0.3.5
Author:
netseeker

Field Summary
 
Fields inherited from class java.io.FilterInputStream
in
 
Constructor Summary
UncloseableInputStream(java.io.InputStream in)
           
UncloseableInputStream(java.io.InputStream in, boolean customEOF)
           
 
Method Summary
 int available()
           
 void close()
           
 int read()
           
 int read(byte[] b)
           
 int read(byte[] b, int off, int len)
           
 
Methods inherited from class java.io.FilterInputStream
mark, markSupported, reset, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UncloseableInputStream

public UncloseableInputStream(java.io.InputStream in)
Parameters:
in -

UncloseableInputStream

public UncloseableInputStream(java.io.InputStream in,
                              boolean customEOF)
Parameters:
in -
customEOF -
Method Detail

close

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

available

public int available()
              throws java.io.IOException
Overrides:
available in class java.io.FilterInputStream
Throws:
java.io.IOException

read

public int read()
         throws java.io.IOException
Overrides:
read in class java.io.FilterInputStream
Throws:
java.io.IOException

read

public int read(byte[] b,
                int off,
                int len)
         throws java.io.IOException
Overrides:
read in class java.io.FilterInputStream
Throws:
java.io.IOException

read

public int read(byte[] b)
         throws java.io.IOException
Overrides:
read in class java.io.FilterInputStream
Throws:
java.io.IOException


Copyright © 2005-2007 netseeker. All Rights Reserved.