@InterfaceAudience.Private public class CompoundBloomFilter extends CompoundBloomFilterBase implements BloomFilter
ByteBloomFilter,
encapsulating a set of fixed-size Bloom filters written out at the time of
HFile generation into the data
block stream, and loaded on demand at query time. This class only provides
reading capabilities.comparator, errorRate, hashType, numChunks, totalByteSize, totalKeyCount, totalMaxKeys, VERSION| 构造器和说明 |
|---|
CompoundBloomFilter(DataInput meta,
HFile.Reader reader)
De-serialization for compound Bloom filter metadata.
|
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
contains(byte[] key,
int keyOffset,
int keyLength,
ByteBuffer bloom)
Check if the specified key is contained in the bloom filter.
|
void |
enableTestingStats() |
String |
formatTestingStats() |
KeyValue.KVComparator |
getComparator() |
int |
getNumChunks() |
long |
getNumPositivesForTesting(int chunk) |
long |
getNumQueriesForTesting(int chunk) |
boolean |
supportsAutoLoading() |
String |
toString() |
createBloomKey, getByteSize, getKeyCount, getMaxKeysclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitcreateBloomKey, getByteSize, getKeyCount, getMaxKeyspublic CompoundBloomFilter(DataInput meta, HFile.Reader reader) throws IOException
CompoundBloomFilterWriter does.meta - serialized Bloom filter metadata without any magic blocksIOExceptionpublic boolean contains(byte[] key,
int keyOffset,
int keyLength,
ByteBuffer bloom)
BloomFiltercontains 在接口中 BloomFilterkey - data to check for existence ofkeyOffset - offset into the datakeyLength - length of the databloom - bloom filter data to search. This can be null if auto-loading
is supported.public boolean supportsAutoLoading()
supportsAutoLoading 在接口中 BloomFilterpublic int getNumChunks()
public KeyValue.KVComparator getComparator()
getComparator 在接口中 BloomFilterBasegetComparator 在类中 CompoundBloomFilterBasepublic void enableTestingStats()
public String formatTestingStats()
public long getNumQueriesForTesting(int chunk)
public long getNumPositivesForTesting(int chunk)
Copyright © 2007–2021 The Apache Software Foundation. All rights reserved.