public class BlockGroup
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
int |
BLOCK_SIZE |
int |
INODE_SIZE |
Constructor and Description |
---|
BlockGroup(java.nio.ByteBuffer block,
boolean debug)
Constructor method.
|
Modifier and Type | Method and Description |
---|---|
java.nio.ByteBuffer |
getBlock(int id)
Accessor function.
|
int |
getFileInodePointer(java.lang.String fileName)
Accessor function.
|
int |
getFileLength(java.lang.String fileName)
Accessor function.
|
Inode |
getInode(int id,
boolean debug)
Accessor function.
|
void |
listDir()
Prints the directory listing.
|
public final int BLOCK_SIZE
public final int INODE_SIZE
public BlockGroup(java.nio.ByteBuffer block, boolean debug)
block
- The blockgroup byte dump.debug
- Whether debug mode is active or not.public java.nio.ByteBuffer getBlock(int id)
id
- The index of the block.public Inode getInode(int id, boolean debug)
id
- The index of the inode.debug
- Whether debug mode is active or not.public void listDir()
public int getFileInodePointer(java.lang.String fileName)
fileName
- The filename.public int getFileLength(java.lang.String fileName)
fileName
- The filename.