pub struct LocalReadDatabase<F: VfsFile> { /* private fields */ }Expand description
Holds the exclusively owned file and reconstructs snapshot + committed WAL once. Callers retain the file lock until this value is dropped. No mutator is exposed.
Implementations§
Source§impl<F: VfsFile> LocalReadDatabase<F>
impl<F: VfsFile> LocalReadDatabase<F>
pub fn open(file: F, name: impl Into<PathBuf>) -> Result<Self, LocalReadError>
pub fn query(&self, sql: &str) -> Result<ScalarResult, LocalReadError>
Auto Trait Implementations§
impl<F> !Freeze for LocalReadDatabase<F>
impl<F> !RefUnwindSafe for LocalReadDatabase<F>
impl<F> !UnwindSafe for LocalReadDatabase<F>
impl<F> Send for LocalReadDatabase<F>where
EmbeddedResidentStore<F>: Send,
impl<F> Sync for LocalReadDatabase<F>where
EmbeddedResidentStore<F>: Sync,
impl<F> Unpin for LocalReadDatabase<F>where
EmbeddedResidentStore<F>: Unpin,
impl<F> UnsafeUnpin for LocalReadDatabase<F>where
EmbeddedResidentStore<F>: UnsafeUnpin,
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more