org.apache.hadoop.hbase.regionserver
Class StoreFile.Reader
java.lang.Object
org.apache.hadoop.hbase.regionserver.StoreFile.Reader
- Direct Known Subclasses:
- HalfStoreFileReader
- Enclosing class:
- StoreFile
public static class StoreFile.Reader
- extends Object
Reader for a StoreFile.
Constructor Summary |
StoreFile.Reader(org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path path,
BlockCache blockCache,
boolean inMemory)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
bloomFilter
protected BloomFilter bloomFilter
bloomFilterType
protected StoreFile.BloomType bloomFilterType
timeRangeTracker
protected TimeRangeTracker timeRangeTracker
sequenceID
protected long sequenceID
StoreFile.Reader
public StoreFile.Reader(org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path path,
BlockCache blockCache,
boolean inMemory)
throws IOException
- Throws:
IOException
getComparator
public org.apache.hadoop.io.RawComparator<byte[]> getComparator()
getStoreFileScanner
public org.apache.hadoop.hbase.regionserver.StoreFileScanner getStoreFileScanner(boolean cacheBlocks,
boolean pread)
- Get a scanner to scan over this StoreFile.
- Parameters:
cacheBlocks
- should this scanner cache blocks?pread
- use pread (for highly concurrent small readers)
- Returns:
- a scanner
getScanner
@Deprecated
public HFileScanner getScanner(boolean cacheBlocks,
boolean pread)
- Deprecated.
- Warning: Do not write further code which depends on this call. Instead
use getStoreFileScanner() which uses the StoreFileScanner class/interface
which is the preferred way to scan a store with higher level concepts.
- Parameters:
cacheBlocks
- should we cache the blocks?pread
- use pread (for concurrent small readers)
- Returns:
- the underlying HFileScanner
close
public void close()
throws IOException
- Throws:
IOException
shouldSeek
public boolean shouldSeek(Scan scan,
SortedSet<byte[]> columns)
loadFileInfo
public Map<byte[],byte[]> loadFileInfo()
throws IOException
- Throws:
IOException
loadBloomfilter
public void loadBloomfilter()
getFilterEntries
public int getFilterEntries()
getMetaBlock
public ByteBuffer getMetaBlock(String bloomFilterDataKey,
boolean cacheBlock)
throws IOException
- Throws:
IOException
setBloomFilterFaulty
public void setBloomFilterFaulty()
getLastKey
public byte[] getLastKey()
midkey
public byte[] midkey()
throws IOException
- Throws:
IOException
length
public long length()
getEntries
public int getEntries()
getFirstKey
public byte[] getFirstKey()
indexSize
public long indexSize()
getBloomFilterType
public StoreFile.BloomType getBloomFilterType()
getSequenceID
public long getSequenceID()
setSequenceID
public void setSequenceID(long sequenceID)
Copyright © 2011 The Apache Software Foundation. All Rights Reserved.