pub struct ConcreteEnv { /* private fields */ }
Expand description
A strongly typed, concrete database environment, backed by heed
.
Trait Implementations§
Source§impl Drop for ConcreteEnv
impl Drop for ConcreteEnv
Source§impl Env for ConcreteEnv
impl Env for ConcreteEnv
Source§type TxRw<'tx> = RefCell<RwTxn<'tx>>
type TxRw<'tx> = RefCell<RwTxn<'tx>>
HACK:
heed::RwTxn
is wrapped in RefCell
to allow:
- opening a database with only a
&
to it - allowing 1 write tx to open multiple tables
Our mutable accesses are safe and will not panic as:
- Write transactions are
!Sync
- A table operation does not hold a reference to the inner cell once the call is over
- The function to manipulate the table takes the same type
of reference that the
RefCell
gets for that function
Also see:
Source§const MANUAL_RESIZE: bool = true
const MANUAL_RESIZE: bool = true
Does the database backend need to be manually
resized when the memory-map is full? Read more
Source§const SYNCS_PER_TX: bool = false
const SYNCS_PER_TX: bool = false
Does the database backend forcefully sync/flush
to disk on every transaction commit? Read more
Source§type EnvInner<'env> = RwLockReadGuard<'env, Env>
type EnvInner<'env> = RwLockReadGuard<'env, Env>
The struct representing the actual backend’s database environment. Read more
Source§fn resize_map(&self, resize_algorithm: Option<ResizeAlgorithm>) -> NonZeroUsize
fn resize_map(&self, resize_algorithm: Option<ResizeAlgorithm>) -> NonZeroUsize
Resize the database’s memory map to a
new (bigger) size using a
ResizeAlgorithm
. Read moreSource§fn current_map_size(&self) -> usize
fn current_map_size(&self) -> usize
What is the current size of the database’s memory map in bytes? Read more
Auto Trait Implementations§
impl !Freeze for ConcreteEnv
impl RefUnwindSafe for ConcreteEnv
impl Send for ConcreteEnv
impl Sync for ConcreteEnv
impl Unpin for ConcreteEnv
impl UnwindSafe for ConcreteEnv
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
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 104 bytes