public class POIFSMiniStore extends BlockStore
POIFSFileSystem
(此类处理 POIFSFileSystem 的 NIO 案例中的 MiniStream(小块存储))
BlockStore.ChainLoopDetector
Modifier and Type | Method and Description |
---|---|
protected java.nio.ByteBuffer |
createBlockIfNeeded(int offset)
Load the block, extending the underlying stream if needed
(加载块,如果需要扩展底层流)
|
protected BATBlock.BATBlockAndIndex |
getBATBlockAndIndex(int offset)
Returns the BATBlock that handles the specified offset, and the relative index within it
(返回处理指定偏移量的 BATBlock,以及其中的相对索引)
|
protected java.nio.ByteBuffer |
getBlockAt(int offset)
Load the block at the given offset.
(在给定的偏移量处加载块。)
|
protected int |
getBlockStoreBlockSize()
Returns the size of the blocks managed through the block store.
(返回通过块存储管理的块的大小。)
|
protected BlockStore.ChainLoopDetector |
getChainLoopDetector()
Creates a Detector for loops in the chain
(为链中的循环创建检测器)
|
protected int |
getFreeBlock()
Finds a free block, and returns its offset.
(找到一个空闲块,并返回它的偏移量。)
|
protected int |
getNextBlock(int offset)
Works out what block follows the specified one.
(计算出指定块后面的块。)
|
protected void |
releaseBuffer(java.nio.ByteBuffer buffer)
Releases a mmap-ed buffer, which you are sure won't be used again
(释放一个 mmap-ed 缓冲区,您确定不会再次使用该缓冲区)
|
protected void |
setNextBlock(int offset, int nextBlock)
Changes the record of what block follows the specified one.
(更改指定块后面的记录。)
|
protected java.nio.ByteBuffer getBlockAt(int offset)
getBlockAt
in class
BlockStore
(类 BlockStore 中的 getBlockAt)
protected java.nio.ByteBuffer createBlockIfNeeded(int offset) throws java.io.IOException
createBlockIfNeeded
in class
BlockStore
(类 BlockStore 中的 createBlockIfNeeded)
java.io.IOException
(java.io.IOException)
protected BATBlock.BATBlockAndIndex getBATBlockAndIndex(int offset)
getBATBlockAndIndex
in class
BlockStore
(类 BlockStore 中的 getBATBlockAndIndex)
protected int getNextBlock(int offset)
getNextBlock
in class
BlockStore
(类 BlockStore 中的 getNextBlock)
protected void setNextBlock(int offset, int nextBlock)
setNextBlock
in class
BlockStore
(类 BlockStore 中的 setNextBlock)
protected int getFreeBlock() throws java.io.IOException
getFreeBlock
in class
BlockStore
(类 BlockStore 中的 getFreeBlock)
java.io.IOException
(java.io.IOException)
protected BlockStore.ChainLoopDetector getChainLoopDetector()
BlockStore
getChainLoopDetector
in class
BlockStore
(类 BlockStore 中的 getChainLoopDetector)
protected int getBlockStoreBlockSize()
BlockStore
getBlockStoreBlockSize
in class
BlockStore
(类 BlockStore 中的 getBlockStoreBlockSize)
protected void releaseBuffer(java.nio.ByteBuffer buffer)
BlockStore
releaseBuffer
in class
BlockStore
(类 BlockStore 中的 releaseBuffer)
buffer
- the buffer
(缓冲区 - 缓冲区)
Copyright 2021 The Apache Software Foundation or its licensors, as applicable.