public class BlockCache extends Object
Constructor and Description |
---|
BlockCache(Metrics metrics,
boolean directAllocation,
long totalMemory) |
BlockCache(Metrics metrics,
boolean directAllocation,
long totalMemory,
int slabSize) |
BlockCache(Metrics metrics,
boolean directAllocation,
long totalMemory,
int slabSize,
int blockSize) |
Modifier and Type | Method and Description |
---|---|
boolean |
fetch(BlockCacheKey blockCacheKey,
byte[] buffer) |
boolean |
fetch(BlockCacheKey blockCacheKey,
byte[] buffer,
int blockOffset,
int off,
int length) |
int |
getSize() |
void |
release(BlockCacheKey key) |
boolean |
store(BlockCacheKey blockCacheKey,
int blockOffset,
byte[] data,
int offset,
int length) |
public static final int _128M
public static final int _32K
public BlockCache(Metrics metrics, boolean directAllocation, long totalMemory)
public BlockCache(Metrics metrics, boolean directAllocation, long totalMemory, int slabSize)
public BlockCache(Metrics metrics, boolean directAllocation, long totalMemory, int slabSize, int blockSize)
public void release(BlockCacheKey key)
public boolean store(BlockCacheKey blockCacheKey, int blockOffset, byte[] data, int offset, int length)
public boolean fetch(BlockCacheKey blockCacheKey, byte[] buffer, int blockOffset, int off, int length)
public boolean fetch(BlockCacheKey blockCacheKey, byte[] buffer)
public int getSize()
Copyright © 2000-2014 Apache Software Foundation. All Rights Reserved.