pub struct ColumnFamilyDescriptor { /* private fields */ }
Expand description
A descriptor for a RocksDB column family.
A description of the column family, containing the name and Options
.
Implementations§
Source§impl ColumnFamilyDescriptor
impl ColumnFamilyDescriptor
Sourcepub fn new<S>(name: S, options: Options) -> Self
pub fn new<S>(name: S, options: Options) -> Self
Create a new column family descriptor with the specified name and options.
WARNING:
Will use ColumnFamilyTtl::SameAsDb
as ttl.
Sourcepub fn new_with_ttl<S>(name: S, options: Options, ttl: ColumnFamilyTtl) -> Self
pub fn new_with_ttl<S>(name: S, options: Options, ttl: ColumnFamilyTtl) -> Self
Create a new column family descriptor with the specified name, options, and ttl.
WARNING:
The ttl is applied only when DB is opened with crate::db::DB::open_with_ttl()
.
Sourcepub fn set_ttl(&mut self, ttl: ColumnFamilyTtl)
pub fn set_ttl(&mut self, ttl: ColumnFamilyTtl)
Sets ttl for the column family. It’s applied only when DB is opened with
crate::db::DB::open_with_ttl()
. Changing ttl after DB is opened has no effect.
pub fn ttl(&self) -> ColumnFamilyTtl
Auto Trait Implementations§
impl Freeze for ColumnFamilyDescriptor
impl RefUnwindSafe for ColumnFamilyDescriptor
impl Send for ColumnFamilyDescriptor
impl Sync for ColumnFamilyDescriptor
impl Unpin for ColumnFamilyDescriptor
impl UnwindSafe for ColumnFamilyDescriptor
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