|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectrossi.fstools.fs.ext2fs.GroupDesc
Representation of ext2/3 group descriptor.
On disk the superblock looks like this:
31 24 16 8 0
--------------------------------------
0000 | Block Bitmap Block |
--------------------------------------
0004 | Inode Bitmap Block |
--------------------------------------
0008 | Inode table |
--------------------------------------
000C | Free Blocks | Free Inodes |
--------------------------------------
0010 | Used Dirs | Pad |
--------------------------------------
0014 | Reserved |
--------------------------------------
0018 | Reserved |
--------------------------------------
001C | Reserved |
--------------------------------------
| Field Summary | |
protected long |
blockBitmap
|
protected int |
freeBlocks
|
protected int |
freeInodes
|
protected long |
inodeBitmap
|
protected long |
inodeTable
|
protected int |
usedDirs
|
| Constructor Summary | |
GroupDesc()
|
|
| Method Summary | |
long |
getBlockBitmap()
Get the location of the block bitmap block for this group. |
int |
getDataSize()
Get the size in bytes of the structure. |
int |
getFreeBlocks()
Get the number of free blocks in this group. |
int |
getFreeInodes()
Get the number of free inodes in this group. |
long |
getInodeBitmap()
Get the location of the inode bitmap block for this group. |
long |
getInodeTable()
Get the location of the inode table for this group. |
int |
getUsedDirs()
Get the number of directories in this group. |
void |
loadFromBuffer(byte[] buffer,
int offset)
Loads the object from a memory buffer |
void |
setBlockBitmap(long aBlockBitmap)
|
void |
setFreeBlocks(int aFreeBlocks)
|
void |
setFreeInodes(int aFreeInodes)
|
void |
setInodeBitmap(long aInodeBitmap)
|
void |
setInodeTable(long aInodeTable)
|
void |
setUsedDirs(int aUsedDirs)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected long blockBitmap
protected long inodeBitmap
protected long inodeTable
protected int freeBlocks
protected int freeInodes
protected int usedDirs
| Constructor Detail |
public GroupDesc()
| Method Detail |
public int getDataSize()
DiskStructure
getDataSize in interface DiskStructurepublic long getBlockBitmap()
public void setBlockBitmap(long aBlockBitmap)
public long getInodeBitmap()
public void setInodeBitmap(long aInodeBitmap)
public long getInodeTable()
public void setInodeTable(long aInodeTable)
public int getFreeBlocks()
public void setFreeBlocks(int aFreeBlocks)
public int getFreeInodes()
public void setFreeInodes(int aFreeInodes)
public int getUsedDirs()
public void setUsedDirs(int aUsedDirs)
public void loadFromBuffer(byte[] buffer,
int offset)
throws FsException
DiskStructure
loadFromBuffer in interface DiskStructurebuffer - a byte[] containing data to be read in populating the objectoffset - a int indicating the offset within the buffer to start parsing.
FsException - if a parse error occurs.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||