# Print output for @column tags ?>
Developers

- Design
- Develop
- Distribute

Developer Console

## Most visited

## Recently visited

## Results for

Summary: Ctors | Methods | Inherited Methods

# ParcelFileDescriptor.AutoCloseInputStream

`public static class ParcelFileDescriptor.AutoCloseInputStream`
`` `` `extends FileInputStream` ``

java.lang.Object
↳ | java.io.InputStream
| ↳ | java.io.FileInputStream
|  | ↳ | android.os.ParcelFileDescriptor.AutoCloseInputStream

Known direct subclasses AssetFileDescriptor.AutoCloseInputStream
AssetFileDescriptor.AutoCloseInputStream | An InputStream you can create on a ParcelFileDescriptor, which will take care of calling `ParcelFileDescriptor#close` for you when the stream is closed.

An InputStream you can create on a ParcelFileDescriptor, which will take care of calling `ParcelFileDescriptor#close` for you when the stream is closed.

## Summary

### Public constructors
`AutoCloseInputStream(ParcelFileDescriptor pfd)`

### Public methods
`void` | `close()` Closes this file input stream and releases any system resources associated with the stream.
`int` | `read()` Reads a byte of data from this input stream.
`int` | `read(byte[] b, int off, int len)` Reads up to `len` bytes of data from this input stream into an array of bytes.
`int` | `read(byte[] b)` Reads up to `b.length` bytes of data from this input stream into an array of bytes.

### Inherited methods
From class `java.io.FileInputStream`
`int` | `available()` Returns an estimate of the number of remaining bytes that can be read (or skipped over) from this input stream without blocking by the next invocation of a method for this input stream.
`void` | `close()` Closes this file input stream and releases any system resources associated with the stream.
`void` | `finalize()` Ensures that the `close` method of this file input stream is called when there are no more references to it.
`FileChannel` | `getChannel()` Returns the unique `FileChannel` object associated with this file input stream.
`final FileDescriptor` | `getFD()` Returns the `FileDescriptor` object that represents the connection to the actual file in the file system being used by this `FileInputStream`.
`int` | `read()` Reads a byte of data from this input stream.
`int` | `read(byte[] b, int off, int len)` Reads up to `len` bytes of data from this input stream into an array of bytes.
`int` | `read(byte[] b)` Reads up to `b.length` bytes of data from this input stream into an array of bytes.
`long` | `skip(long n)` Skips over and discards `n` bytes of data from the input stream.
From class `java.io.InputStream`
`int` | `available()` Returns an estimate of the number of bytes that can be read (or skipped over) from this input stream without blocking by the next invocation of a method for this input stream.
`void` | `close()` Closes this input stream and releases any system resources associated with the stream.
`void` | `mark(int readlimit)` Marks the current position in this input stream.
`boolean` | `markSupported()` Tests if this input stream supports the `mark` and `reset` methods.
`abstract int` | `read()` Reads the next byte of data from the input stream.
`int` | `read(byte[] b, int off, int len)` Reads up to `len` bytes of data from the input stream into an array of bytes.
`int` | `read(byte[] b)` Reads some number of bytes from the input stream and stores them into the buffer array `b`.
`void` | `reset()` Repositions this stream to the position at the time the `mark` method was last called on this input stream.
`long` | `skip(long n)` Skips over and discards `n` bytes of data from this input stream.
From class `java.lang.Object`
`Object` | `clone()` Creates and returns a copy of this object.
`boolean` | `equals(Object obj)` Indicates whether some other object is "equal to" this one.
`void` | `finalize()` Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.
`final Class<?>` | `getClass()` Returns the runtime class of this `Object`.
`int` | `hashCode()` Returns a hash code value for the object.
`final void` | `notify()` Wakes up a single thread that is waiting on this object's monitor.
`final void` | `notifyAll()` Wakes up all threads that are waiting on this object's monitor.
`String` | `toString()` Returns a string representation of the object.
`final void` | `wait(long timeout, int nanos)` Causes the current thread to wait until another thread invokes the `notify()` method or the `notifyAll()` method for this object, or some other thread interrupts the current thread, or a certain amount of real time has elapsed.
`final void` | `wait(long timeout)` Causes the current thread to wait until either another thread invokes the `notify()` method or the `notifyAll()` method for this object, or a specified amount of time has elapsed.
`final void` | `wait()` Causes the current thread to wait until another thread invokes the `notify()` method or the `notifyAll()` method for this object.
From interface `java.io.Closeable`
`abstract void` | `close()` Closes this stream and releases any system resources associated with it.
From interface `java.lang.AutoCloseable`
`abstract void` | `close()` Closes this resource, relinquishing any underlying resources.

## Public constructors

### AutoCloseInputStream

    public AutoCloseInputStream (ParcelFileDescriptor pfd)

Parameters
`pfd` | `ParcelFileDescriptor`

## Public methods

### close

    public void close ()

Closes this file input stream and releases any system resources associated with the stream.

If this stream has an associated channel then the channel is closed as well.

Throws
`IOException` |

### read

    public int read ()

Reads a byte of data from this input stream. This method blocks if no input is yet available.

Returns
`int` | the next byte of data, or `-1` if the end of the file is reached.

Throws
`IOException` |

### read

    public int read (byte[] b,
                    int off,
                    int len)

Reads up to `len` bytes of data from this input stream into an array of bytes. If `len` is not zero, the method blocks until some input is available; otherwise, no bytes are read and `0` is returned.

Parameters
`b` | `byte`: the buffer into which the data is read.
`off` | `int`: the start offset in the destination array `b`
`len` | `int`: the maximum number of bytes read.

Returns
`int` | the total number of bytes read into the buffer, or `-1` if there is no more data because the end of the file has been reached.

Throws
`IOException` |

### read

    public int read (byte[] b)

Reads up to `b.length` bytes of data from this input stream into an array of bytes. This method blocks until some input is available.

Parameters
`b` | `byte`: the buffer into which the data is read.

Returns
`int` | the total number of bytes read into the buffer, or `-1` if there is no more data because the end of the file has been reached.

Throws
`IOException` |

Full name *
Email address *
Company / developer name
One of your Play Store app URLs *
Which best describes your business:*
Apps
Games
Apps & Games
*
*