|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.poi.poifs.storage.BATBlock
public class BATBlock
A block of block allocation table entries. BATBlocks are created only through a static factory method: createBATBlocks.
| Method Summary | |
|---|---|
static int |
calculateStorageRequirements(int entryCount)
Calculate how many BATBlocks are needed to hold a specified number of BAT entries. |
static int |
calculateXBATStorageRequirements(int entryCount)
Calculate how many XBATBlocks are needed to hold a specified number of BAT entries. |
static BATBlock[] |
createBATBlocks(int[] entries)
Create an array of BATBlocks from an array of int block allocation table entries |
static BATBlock[] |
createXBATBlocks(int[] entries,
int startBlock)
Create an array of XBATBlocks from an array of int block allocation table entries |
protected void |
doWriteData(java.io.OutputStream stream,
byte[] data)
Default implementation of write for extending classes that contain their data in a simple array of bytes. |
static int |
entriesPerBlock()
|
static int |
entriesPerXBATBlock()
|
static int |
getXBATChainOffset()
|
void |
writeBlocks(java.io.OutputStream stream)
Write the storage to an OutputStream |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static BATBlock[] createBATBlocks(int[] entries)
entries - the array of int entries
public static BATBlock[] createXBATBlocks(int[] entries,
int startBlock)
entries - the array of int entriesstartBlock - the start block of the array of XBAT blocks
public static int calculateStorageRequirements(int entryCount)
entryCount - the number of entries
public static int calculateXBATStorageRequirements(int entryCount)
entryCount - the number of entries
public static final int entriesPerBlock()
public static final int entriesPerXBATBlock()
public static final int getXBATChainOffset()
protected void doWriteData(java.io.OutputStream stream,
byte[] data)
throws java.io.IOException
stream - the OutputStream to which the data should be
written.data - the byte array of to be written.
java.io.IOException - on problems writing to the specified
stream.
public void writeBlocks(java.io.OutputStream stream)
throws java.io.IOException
writeBlocks in interface BlockWritablestream - the OutputStream to which the stored data should
be written
java.io.IOException - on problems writing to the specified
stream
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||