Struct mocklogger::logger::Builder
source · pub struct Builder { /* private fields */ }Implementations§
source§impl Builder
impl Builder
sourcepub fn datastore(self, ds: Datastore) -> Self
pub fn datastore(self, ds: Datastore) -> Self
Set the datastore
If this is not called, it will use a temporary datastore
sourcepub async fn datastore_pool(self, p: &SqlitePool) -> Self
pub async fn datastore_pool(self, p: &SqlitePool) -> Self
Set the datastore from a pool
Replaces the datastore with one based from the pool
sourcepub fn development(self, val: bool) -> Self
pub fn development(self, val: bool) -> Self
Set development mode to true/false
default is false
pub async fn build(self) -> Result<Logger, LogErr>
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl !UnwindSafe for Builder
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> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn 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.