Package org.apache.commons.io.input

# Class AbstractInputStream

java.lang.Object
java.io.InputStream
org.apache.commons.io.input.AbstractInputStream

All Implemented Interfaces:
  `Closeable`, `AutoCloseable`

Direct Known Subclasses:
  `CircularInputStream`, `MemoryMappedFileInputStream`, `NullInputStream`, `RandomAccessFileInputStream`, `ReaderInputStream`

public abstract class AbstractInputStream extends InputStream
Abstracts some InputStream operations for implementations in this package.

Since:
  2.17.0

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `AbstractInputStream()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `close()`
  `boolean`
  `isClosed()`
  Tests whether this instance is closed; if `close()` completed successfully.
  `void`
  `setClosed(boolean closed)`
  Sets whether this instance is closed.

  ### Methods inherited from class java.io.InputStream

  `available, mark, markSupported, read, read, read, reset, skip`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### AbstractInputStream

    public AbstractInputStream()

- ## Method Details

  - ### close

    public void close() throws IOException
    Specified by:
      `close` in interface `AutoCloseable`
    Specified by:
      `close` in interface `Closeable`
    Overrides:
      `close` in class `InputStream`
    Throws:
      `IOException`

  - ### isClosed

    public boolean isClosed()
    Tests whether this instance is closed; if `close()` completed successfully.
    Returns:
      whether this instance is closed.

  - ### setClosed

    public void setClosed(boolean closed)
    Sets whether this instance is closed.
    Parameters:
      `closed` - whether this instance is closed.