FileDocCategorySizeDatePackage
ClosedInputStream.javaAPI DocAndroid 1.5 API1666Wed May 06 22:42:46 BST 2009org.apache.commons.io.input

ClosedInputStream

public class ClosedInputStream extends InputStream
Closed input stream. This stream returns -1 to all attempts to read something from the stream.

Typically uses of this class include testing for corner cases in methods that accept input streams and acting as a sentinel value instead of a null input stream.

version
$Id: ClosedInputStream.java 601751 2007-12-06 14:55:45Z niallp $
since
Commons IO 1.4

Fields Summary
public static final ClosedInputStream
CLOSED_INPUT_STREAM
A singleton.
Constructors Summary
Methods Summary
public intread()
Returns -1 to indicate that the stream is closed.

return
always -1


                     
       
        return -1;