org.apache.poi.poifs.storage
Class BlockAllocationTableReader
- java.lang.Object
-
- org.apache.poi.poifs.storage.BlockAllocationTableReader
-
public final class BlockAllocationTableReader extends java.lang.ObjectThis class manages and creates the Block Allocation Table, which is basically a set of linked lists of block indices.Each block of the filesystem has an index. The first block, the header, is skipped; the first block after the header is index 0, the next is index 1, and so on.
A block's index is also its index into the Block Allocation Table. The entry that it finds in the Block Allocation Table is the index of the next block in the linked list of blocks making up a file, or it is set to -2: end of list.
-
-
Constructor Summary
Constructors Constructor and Description BlockAllocationTableReader(POIFSBigBlockSize bigBlockSize, int block_count, int[] block_array, int xbat_count, int xbat_index, BlockList raw_block_list)create a BlockAllocationTableReader for an existing filesystem.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static voidsanityCheckBlockCount(int block_count)
-
-
-
Constructor Detail
-
BlockAllocationTableReader
public BlockAllocationTableReader(POIFSBigBlockSize bigBlockSize, int block_count, int[] block_array, int xbat_count, int xbat_index, BlockList raw_block_list) throws java.io.IOException
create a BlockAllocationTableReader for an existing filesystem. Side effect: when this method finishes, the BAT blocks will have been removed from the raw block list, and any blocks labeled as 'unused' in the block allocation table will also have been removed from the raw block list.- Parameters:
block_count- the number of BAT blocks making up the block allocation tableblock_array- the array of BAT block indices from the filesystem's headerxbat_count- the number of XBAT blocksxbat_index- the index of the first XBAT blockraw_block_list- the list of RawDataBlocks- Throws:
java.io.IOException- if, in trying to create the table, we encounter logic errors
-
-
DataMelt 3.0 © DataMelt by jWork.ORG