Struct modio_logger_db::SqlitePoolBuilder
source · pub struct SqlitePoolBuilder<'tempfile> { /* private fields */ }Expand description
Helper around building a pool
Implementations
sourceimpl<'tempfile> SqlitePoolBuilder<'tempfile>
impl<'tempfile> SqlitePoolBuilder<'tempfile>
pub fn new() -> Self
sourcepub fn db_path(self, path: &'tempfile Path) -> Self
pub fn db_path(self, path: &'tempfile Path) -> Self
Set the db_path
It is expected that it is a reference to a path that should exist on disk,
and be visible by it’s filename.
The caller is expected to ensure that the file exists.
pub fn migrate(self, migrate: bool) -> Self
pub async fn build(self) -> Result<SqlitePool, Error>
Trait Implementations
Auto Trait Implementations
impl<'tempfile> RefUnwindSafe for SqlitePoolBuilder<'tempfile>
impl<'tempfile> Send for SqlitePoolBuilder<'tempfile>
impl<'tempfile> Sync for SqlitePoolBuilder<'tempfile>
impl<'tempfile> Unpin for SqlitePoolBuilder<'tempfile>
impl<'tempfile> UnwindSafe for SqlitePoolBuilder<'tempfile>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere
T: Default,
type NoneType = T
fn null_value() -> T
fn null_value() -> T
The none-equivalent value.