public class Superblock
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private int |
blockCount |
private int |
blocksPerGroup |
private java.nio.ByteBuffer |
buffer |
private int |
inodeCount |
private int |
inodesPerGroup |
private int |
sInodeSize |
private short |
sMagic |
private java.lang.String |
volumeName |
| Constructor and Description |
|---|
Superblock(byte[] bytes)
Constructor of the Superblock class
|
| Modifier and Type | Method and Description |
|---|---|
(package private) int |
getBlockCount() |
(package private) int |
getBlockGroupCount(int num_of_blocks,
int blocks_per_group) |
(package private) int |
getBlocksPerGroup() |
(package private) int |
getInodeCount() |
(package private) int |
getInodeSize() |
(package private) int |
getInodesPerGroup() |
(package private) java.lang.String |
getVolumeName() |
(package private) void |
printGenericData(int inodeSize,
int blockGroupCount) |
private void |
read()
This method will readBytes all the data that is contained in the Superblock,
from the buffer in which the byte array was parsed
|
private short sMagic
private int inodeCount
private int blockCount
private int blocksPerGroup
private int inodesPerGroup
private int sInodeSize
private java.lang.String volumeName
private java.nio.ByteBuffer buffer
public Superblock(byte[] bytes)
bytes - is the byte array that contains the Superblock's dataprivate void read()
int getInodeSize()
int getInodeCount()
int getInodesPerGroup()
int getBlockCount()
int getBlocksPerGroup()
java.lang.String getVolumeName()
int getBlockGroupCount(int num_of_blocks,
int blocks_per_group)
num_of_blocks - the total number of blocks in the filesystemblocks_per_group - the total number of blocks in every block groupvoid printGenericData(int inodeSize,
int blockGroupCount)