public class InodeBlobInputStream
extends java.io.InputStream
Constructor and Description |
---|
InodeBlobInputStream(BlockStore store,
byte[] inode,
int inodeOffset)
Creates a blob output stream.
|
InodeBlobInputStream(Inode inode)
Creates a blob output stream.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the buffer.
|
void |
init(BlockStore store,
byte[] inode,
int inodeOffset)
Initialize the output stream.
|
int |
read()
Reads a byte.
|
int |
read(byte[] buf,
int offset,
int length)
Reads a buffer.
|
void |
readBlock()
Updates the buffer.
|
static long |
readLong(byte[] buffer,
int offset)
Writes the long.
|
public InodeBlobInputStream(BlockStore store, byte[] inode, int inodeOffset)
store
- the output storepublic InodeBlobInputStream(Inode inode)
store
- the output storepublic void init(BlockStore store, byte[] inode, int inodeOffset)
public int read() throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public int read(byte[] buf, int offset, int length) throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public void close()
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.InputStream
public void readBlock() throws java.io.IOException
java.io.IOException
public static long readLong(byte[] buffer, int offset)