pub struct LevelMetaData { /* private fields */ }Expand description
The metadata that describes one level of a column family’s LSM tree.
Obtained from a ColumnFamilyMetaData query.
The value is a snapshot taken when the metadata was collected and does not
track later compactions or flushes.
Implementations§
Source§impl LevelMetaData
impl LevelMetaData
Sourcepub fn level(&self) -> i32
pub fn level(&self) -> i32
The level this metadata describes, for example 0 for L0.
Do not assume this equals the index the value was read at: the filtered
GetColumnFamilyMetaData overload skips levels with no matching files,
so indices are not level numbers.
Sourcepub fn file_count(&self) -> usize
pub fn file_count(&self) -> usize
Number of SST files in this level.
Sourcepub fn sst_file(&self, index: usize) -> Option<SstFileMetaData>
pub fn sst_file(&self, index: usize) -> Option<SstFileMetaData>
Metadata for the indexth SST file of this level, or None if index
is out of range.
For level 0 the files are ordered most-recently-updated first; for level 1 and above they are ordered by increasing key range.
Sourcepub fn sst_files(&self) -> impl Iterator<Item = SstFileMetaData> + '_
pub fn sst_files(&self) -> impl Iterator<Item = SstFileMetaData> + '_
Iterates the SST files of this level in order.
Trait Implementations§
Source§impl Debug for LevelMetaData
impl Debug for LevelMetaData
Source§impl Drop for LevelMetaData
impl Drop for LevelMetaData
impl Send for LevelMetaData
Auto Trait Implementations§
impl !Sync for LevelMetaData
impl Freeze for LevelMetaData
impl RefUnwindSafe for LevelMetaData
impl Unpin for LevelMetaData
impl UnsafeUnpin for LevelMetaData
impl UnwindSafe for LevelMetaData
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more