Struct slog_async::AsyncCoreBuilder
[−]
[src]
pub struct AsyncCoreBuilder<D> where
D: Drain<Err = Never, Ok = ()> + Send + 'static, { /* fields omitted */ }AsyncCore builder
Methods
impl<D> AsyncCoreBuilder<D> where
D: Drain<Err = Never, Ok = ()> + Send + 'static, [src]
D: Drain<Err = Never, Ok = ()> + Send + 'static,
pub fn thread_name(self, name: String) -> Self[src]
Configure a name to be used for the background thread.
The name must not contain '\0'.
Panics
If a name with '\0' is passed.
pub fn chan_size(self, s: usize) -> Self[src]
Set channel size used to send logging records to worker thread. When
buffer is full AsyncCore will start returning AsyncError::Full or block, depending on
the blocking configuration.
pub fn blocking(self, blocking: bool) -> Self[src]
Should the logging call be blocking if the channel is full?
Default is false, in which case it'll return AsyncError::Full.
pub fn build(self) -> AsyncCore[src]
Build AsyncCore
pub fn build_no_guard(self) -> AsyncCore[src]
Build AsyncCore
pub fn build_with_guard(self) -> (AsyncCore, AsyncGuard)[src]
Build AsyncCore with AsyncGuard
See AsyncGuard for more information.
Trait Implementations
Auto Trait Implementations
impl<D> Send for AsyncCoreBuilder<D>
impl<D> Sync for AsyncCoreBuilder<D> where
D: Sync,
D: Sync,