Package loci.poi.poifs.storage
Class SmallBlockTableWriter
java.lang.Object
loci.poi.poifs.storage.SmallBlockTableWriter
- All Implemented Interfaces:
BATManaged,BlockWritable
This class implements storage for writing the small blocks used by
small documents.
- Author:
- Marc Johnson (mjohnson at apache dot org)
-
Constructor Summary
ConstructorsConstructorDescriptionSmallBlockTableWriter(List documents, RootProperty root) Creates new SmallBlockTable -
Method Summary
Modifier and TypeMethodDescriptionintReturn the number of BigBlock's this instance usesgetSBAT()Get the SBATintGet the number of SBAT blocksvoidsetStartBlock(int start_block) Set the start block for this instancevoidwriteBlocks(OutputStream stream) Write the storage to an OutputStream
-
Constructor Details
-
SmallBlockTableWriter
Creates new SmallBlockTable- Parameters:
documents- a List of POIFSDocument instancesroot- the Filesystem's root property
-
-
Method Details
-
getSBATBlockCount
public int getSBATBlockCount()Get the number of SBAT blocks- Returns:
- number of SBAT big blocks
-
getSBAT
Get the SBAT- Returns:
- the Small Block Allocation Table
-
countBlocks
public int countBlocks()Return the number of BigBlock's this instance uses- Specified by:
countBlocksin interfaceBATManaged- Returns:
- count of BigBlock instances
-
setStartBlock
public void setStartBlock(int start_block) Set the start block for this instance- Specified by:
setStartBlockin interfaceBATManaged- Parameters:
start_block-
-
writeBlocks
Write the storage to an OutputStream- Specified by:
writeBlocksin interfaceBlockWritable- Parameters:
stream- the OutputStream to which the stored data should be written- Throws:
IOException- on problems writing to the specified stream
-