|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface BlockCache
Block cache interface.
Method Summary | |
---|---|
CacheEntry |
cacheBlock(String blockName,
byte[] buf)
Add block to cache (defaults to not in-memory). |
CacheEntry |
cacheBlock(String blockName,
byte[] buf,
boolean inMemory)
Add block to cache. |
CacheEntry |
getBlock(String blockName)
Fetch block from cache. |
long |
getMaxSize()
Get the maximum size of this cache. |
void |
shutdown()
Shutdown the cache. |
Method Detail |
---|
CacheEntry cacheBlock(String blockName, byte[] buf, boolean inMemory)
blockName
- Zero-based file block number.buf
- The block contents wrapped in a ByteBuffer.inMemory
- Whether block should be treated as in-memoryCacheEntry cacheBlock(String blockName, byte[] buf)
blockName
- Zero-based file block number.buf
- The block contents wrapped in a ByteBuffer.CacheEntry getBlock(String blockName)
blockName
- Block number to fetch.
void shutdown()
long getMaxSize()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |