[][src]Struct tracing_fmt::Builder

pub struct Builder<N = NewRecorder, E = Format<Full>, F = EnvFilter> { /* fields omitted */ }

Configures and constructs FmtSubscribers.

Methods

impl<N, E, F> Builder<N, E, F> where
    N: for<'a> NewVisitor<'a> + 'static,
    E: FormatEvent<N> + 'static,
    F: Filter<N> + 'static, 
[src]

pub fn finish(self) -> FmtSubscriber<N, E, F>[src]

impl<N, L, T, F> Builder<N, Format<L, T>, F> where
    N: for<'a> NewVisitor<'a> + 'static,
    F: Filter<N> + 'static, 
[src]

pub fn with_timer<T2>(self, timer: T2) -> Builder<N, Format<L, T2>, F>[src]

Use the given timer for log message timestamps.

pub fn without_time(self) -> Builder<N, Format<L, ()>, F>[src]

Do not emit timestamps with log messages.

pub fn with_ansi(self, ansi: bool) -> Builder<N, Format<L, T>, F>[src]

Enable ANSI encoding for formatted events.

pub fn with_target(self, display_target: bool) -> Builder<N, Format<L, T>, F>[src]

Sets whether or not an event's target is displayed.

impl<N, E, F> Builder<N, E, F> where
    F: Filter<N> + 'static, 
[src]

pub fn with_filter_reloading(self) -> Builder<N, E, ReloadFilter<F, N>>[src]

Configures the subscriber being built to allow filter reloading at runtime.

impl<N, E, F> Builder<N, E, ReloadFilter<F, N>> where
    F: Filter<N> + 'static, 
[src]

pub fn reload_handle(&self) -> Handle<F, N>[src]

Returns a Handle that may be used to reload the constructed subscriber's filter.

impl<N, E, F> Builder<N, E, F>[src]

pub fn with_visitor<N2>(self, new_visitor: N2) -> Builder<N2, E, F> where
    N2: for<'a> NewVisitor<'a> + 'static, 
[src]

Sets the Visitor that the subscriber being built will use to record fields.

pub fn with_filter<F2>(self, filter: F2) -> Builder<N, E, F2> where
    F2: Filter<N> + 'static, 
[src]

Sets the filter that the subscriber being built will use to determine if a span or event is enabled.

pub fn compact(self) -> Builder<N, Format<Compact>, F> where
    N: for<'a> NewVisitor<'a> + 'static, 
[src]

Sets the subscriber being built to use a less verbose formatter.

See format::Compact.

pub fn on_event<E2>(self, fmt_event: E2) -> Builder<N, E2, F> where
    E2: FormatEvent<N> + 'static, 
[src]

Sets the function that the subscriber being built should use to format events that occur.

pub fn inherit_fields(self, inherit_fields: bool) -> Self[src]

Sets whether or not spans inherit their parents' field values (disabled by default).

Trait Implementations

impl<N: Default, E: Default, F: Default> Default for Builder<N, E, F>[src]

impl Default for Builder[src]

impl<N: Debug, E: Debug, F: Debug> Debug for Builder<N, E, F>[src]

Auto Trait Implementations

impl<N, E, F> Sync for Builder<N, E, F> where
    E: Sync,
    F: Sync,
    N: Sync

impl<N, E, F> Unpin for Builder<N, E, F> where
    E: Unpin,
    F: Unpin,
    N: Unpin

impl<N, E, F> Send for Builder<N, E, F> where
    E: Send,
    F: Send,
    N: Send

impl<N, E, F> UnwindSafe for Builder<N, E, F> where
    E: UnwindSafe,
    F: UnwindSafe,
    N: UnwindSafe

impl<N, E, F> RefUnwindSafe for Builder<N, E, F> where
    E: RefUnwindSafe,
    F: RefUnwindSafe,
    N: RefUnwindSafe

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Erased for T[src]