Package org.eclipse.birt.core.archive.compound

# Class ArchiveEntryInputStream

java.lang.Object
java.io.InputStream
org.eclipse.birt.core.archive.RAInputStream
org.eclipse.birt.core.archive.compound.ArchiveEntryInputStream

All Implemented Interfaces:
  `Closeable`, `AutoCloseable`

public class ArchiveEntryInputStream extends RAInputStream
RAInputStream implementation based on the ArchiveEntry.

## Method Summary

Modifier and Type
Method
Description
`int`
`available()`
Returns the number of bytes that can be read (or skipped over) from this random access input stream without blocking by the next caller of a method for this input stream.
`void`
`close()`
`long`
`getOffset()`
`long`
`length()`
`int`
`read()`
`int`
`read(byte[] b, int off, int len)`
`void`
`readFully(byte[] b, int off, int len)`
`int`
`readInt()`
`long`
`readLong()`
`void`
`refresh()`
`void`
`seek(long localPos)`

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

`mark, markSupported, nullInputStream, read, readAllBytes, readNBytes, readNBytes, reset, skip, skipNBytes, transferTo`

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

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

## 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`

### read

public int read() throws IOException

Specified by:
  `read` in class `InputStream`
Throws:
  `IOException`

### available

public int available() throws IOException
Description copied from class: `RAInputStream`
Returns the number of bytes that can be read (or skipped over) from this random access input stream without blocking by the next caller of a method for this input stream. The next caller might be the same thread or another thread.

This abstract class is extended by `RAFolderInputStream` and `RAFileInputStream`

The `available` method returns `-1` when no more data because the end of the stream has been reached.

and returns `Integer.MAX_VALUE` when bytes of data is larger then Integer.MAX_VALUE.

Specified by:
  `available` in class `RAInputStream`
Throws:
  `IOException`

### getOffset

public long getOffset() throws IOException

Specified by:
  `getOffset` in class `RAInputStream`
Throws:
  `IOException`

### length

public long length() throws IOException

Specified by:
  `length` in class `RAInputStream`
Throws:
  `IOException`

### readFully

public void readFully(byte[] b, int off, int len) throws IOException

Specified by:
  `readFully` in class `RAInputStream`
Throws:
  `IOException`

### read

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

Overrides:
  `read` in class `InputStream`
Throws:
  `IOException`

### readInt

public int readInt() throws IOException

Specified by:
  `readInt` in class `RAInputStream`
Returns:
Throws:
  `IOException`

### readLong

public long readLong() throws IOException

Specified by:
  `readLong` in class `RAInputStream`
Throws:
  `IOException`

### refresh

public void refresh() throws IOException

Specified by:
  `refresh` in class `RAInputStream`
Throws:
  `IOException`

### seek

public void seek(long localPos) throws IOException

Specified by:
  `seek` in class `RAInputStream`
Parameters:
  `localPos` -
Throws:
  `IOException`