org.apache.hadoop.hbase.regionserver
Class NonReversedNonLazyKeyValueScanner
java.lang.Object
org.apache.hadoop.hbase.regionserver.NonLazyKeyValueScanner
org.apache.hadoop.hbase.regionserver.NonReversedNonLazyKeyValueScanner
- All Implemented Interfaces:
- KeyValueScanner
- Direct Known Subclasses:
- CollectionBackedScanner, KeyValueHeap, StoreScanner
@InterfaceAudience.Private
public abstract class NonReversedNonLazyKeyValueScanner
- extends NonLazyKeyValueScanner
A "non-reversed & non-lazy" scanner which does not support backward scanning
and always does a real seek operation. Most scanners are inherited from this
class.
Method Summary |
boolean |
backwardSeek(KeyValue key)
Seek the scanner at or before the row of specified KeyValue, it firstly
tries to seek the scanner at or after the specified KeyValue, return if
peek KeyValue of scanner has the same row with specified KeyValue,
otherwise seek the scanner at the first KeyValue of the row which is the
previous row of specified KeyValue |
boolean |
seekToLastRow()
Seek the scanner at the first KeyValue of last row |
boolean |
seekToPreviousRow(KeyValue key)
Seek the scanner at the first KeyValue of the row which is the previous row
of specified key |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NonReversedNonLazyKeyValueScanner
public NonReversedNonLazyKeyValueScanner()
backwardSeek
public boolean backwardSeek(KeyValue key)
throws IOException
- Description copied from interface:
KeyValueScanner
- Seek the scanner at or before the row of specified KeyValue, it firstly
tries to seek the scanner at or after the specified KeyValue, return if
peek KeyValue of scanner has the same row with specified KeyValue,
otherwise seek the scanner at the first KeyValue of the row which is the
previous row of specified KeyValue
- Parameters:
key
- seek KeyValue
- Returns:
- true if the scanner is at the valid KeyValue, false if such
KeyValue does not exist
- Throws:
IOException
seekToPreviousRow
public boolean seekToPreviousRow(KeyValue key)
throws IOException
- Description copied from interface:
KeyValueScanner
- Seek the scanner at the first KeyValue of the row which is the previous row
of specified key
- Parameters:
key
- seek value
- Returns:
- true if the scanner at the first valid KeyValue of previous row,
false if not existing such KeyValue
- Throws:
IOException
seekToLastRow
public boolean seekToLastRow()
throws IOException
- Description copied from interface:
KeyValueScanner
- Seek the scanner at the first KeyValue of last row
- Returns:
- true if scanner has values left, false if the underlying data is
empty
- Throws:
IOException
Copyright © 2007–2015 The Apache Software Foundation. All rights reserved.