org.jaudiotagger.audio.asf.io
Class RandomAccessFileInputstream
java.lang.Object
java.io.InputStream
org.jaudiotagger.audio.asf.io.RandomAccessFileInputstream
- All Implemented Interfaces:
- java.io.Closeable
public final class RandomAccessFileInputstream
- extends java.io.InputStream
Wraps a RandomAccessFile
into an InputStream
.
- Author:
- Christian Laireiter
Field Summary |
private java.io.RandomAccessFile |
source
The file access to read from.
|
Constructor Summary |
RandomAccessFileInputstream(java.io.RandomAccessFile file)
Creates an instance that will provide InputStream functionality
on the given RandomAccessFile by delegating calls.
|
Method Summary |
int |
read()
|
int |
read(byte[] buffer,
int off,
int len)
|
long |
skip(long amount)
|
Methods inherited from class java.io.InputStream |
available, close, mark, markSupported, read, reset |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
source
private final java.io.RandomAccessFile source
- The file access to read from.
RandomAccessFileInputstream
public RandomAccessFileInputstream(java.io.RandomAccessFile file)
- Creates an instance that will provide
InputStream
functionality
on the given RandomAccessFile
by delegating calls.
- Parameters:
file
- The file to read.
read
public int read()
throws java.io.IOException
-
- Specified by:
read
in class java.io.InputStream
- Throws:
java.io.IOException
read
public int read(byte[] buffer,
int off,
int len)
throws java.io.IOException
-
- Overrides:
read
in class java.io.InputStream
- Throws:
java.io.IOException
skip
public long skip(long amount)
throws java.io.IOException
-
- Overrides:
skip
in class java.io.InputStream
- Throws:
java.io.IOException