Struct tikv::storage::Cursor [−][src]
Fields
iter: I
scan_mode: ScanMode
prefix_seek: bool
min_key: Option<Vec<u8, Global>>
max_key: Option<Vec<u8, Global>>
cur_key_has_read: Cell<bool>
cur_value_has_read: Cell<bool>
Implementations
impl<I> Cursor<I> where
I: Iterator,
[src][−]
I: Iterator,
pub fn new(iter: I, mode: ScanMode, prefix_seek: bool) -> Cursor<I>
[src]
pub fn seek(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
[src]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
pub fn near_seek(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
[src][−]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
Seek the specified key.
This method assume the current position of cursor is
around key
, otherwise you should use seek
instead.
pub fn get(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<Option<&[u8]>, Error>
[src][−]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<Option<&[u8]>, Error>
Get the value of specified key.
This method assume the current position of cursor is
around key
, otherwise you should seek
first.
pub fn seek_for_prev(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
[src]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
pub fn near_seek_for_prev(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
[src][−]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
Find the largest key that is not greater than the specific key.
pub fn reverse_seek(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
[src]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
pub fn near_reverse_seek(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
[src][−]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
Reverse seek the specified key.
This method assume the current position of cursor is
around key
, otherwise you should use reverse_seek
instead.
pub fn key(&self, statistics: &mut CfStatistics) -> &[u8]
[src]
pub fn value(&self, statistics: &mut CfStatistics) -> &[u8]
[src]
pub fn seek_to_first(&mut self, statistics: &mut CfStatistics) -> bool
[src]
pub fn seek_to_last(&mut self, statistics: &mut CfStatistics) -> bool
[src]
pub fn internal_seek(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
[src]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
pub fn internal_seek_for_prev(
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
[src]
&mut self,
key: &Key,
statistics: &mut CfStatistics
) -> Result<bool, Error>
pub fn next(&mut self, statistics: &mut CfStatistics) -> bool
[src]
pub fn prev(&mut self, statistics: &mut CfStatistics) -> bool
[src]
pub fn valid(&self) -> Result<bool, Error>
[src]
Auto Trait Implementations
impl<I> !RefUnwindSafe for Cursor<I>
impl<I> Send for Cursor<I>
impl<I> !Sync for Cursor<I>
impl<I> Unpin for Cursor<I> where
I: Unpin,
I: Unpin,
impl<I> UnwindSafe for Cursor<I> where
I: UnwindSafe,
I: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src][+]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<V, W> ConvertFrom<W> for V where
W: ConvertTo<V>,
[src][+]
W: ConvertTo<V>,
impl<T> From<T> for T
[src][+]
impl<T> Instrument for T
[src][+]
impl<T, U> Into<U> for T where
U: From<T>,
[src][+]
U: From<T>,
impl<T> Pointable for T
[src][+]
impl<T> Pointable for T
[src][+]
impl<T> Same<T> for T
[src]
type Output = T
Should always be Self
impl<T> Sealed<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src][+]
U: Into<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src][+]
U: TryFrom<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
[src][+]
V: MultiLane<T>,