pub struct FieldFn<F>(/* private fields */);Available on crate features
fmt and std and tracing only.Expand description
A FormatFields implementation that formats fields by calling a function
or closure.
Trait Implementations§
Source§impl<'a, F> MakeVisitor<Writer<'a>> for FieldFn<F>
impl<'a, F> MakeVisitor<Writer<'a>> for FieldFn<F>
Source§type Visitor = FieldFnVisitor<'a, F>
type Visitor = FieldFnVisitor<'a, F>
The visitor type produced by this
MakeVisitor.Source§fn make_visitor(
&self,
writer: Writer<'a>,
) -> <FieldFn<F> as MakeVisitor<Writer<'a>>>::Visitor
fn make_visitor( &self, writer: Writer<'a>, ) -> <FieldFn<F> as MakeVisitor<Writer<'a>>>::Visitor
Make a new visitor for the provided
target.Auto Trait Implementations§
impl<F> Freeze for FieldFn<F>where
F: Freeze,
impl<F> RefUnwindSafe for FieldFn<F>where
F: RefUnwindSafe,
impl<F> Send for FieldFn<F>where
F: Send,
impl<F> Sync for FieldFn<F>where
F: Sync,
impl<F> Unpin for FieldFn<F>where
F: Unpin,
impl<F> UnsafeUnpin for FieldFn<F>where
F: UnsafeUnpin,
impl<F> UnwindSafe for FieldFn<F>where
F: UnwindSafe,
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<'writer, M> FormatFields<'writer> for Mwhere
M: MakeOutput<Writer<'writer>, Result<(), Error>>,
<M as MakeVisitor<Writer<'writer>>>::Visitor: VisitFmt + VisitOutput<Result<(), Error>>,
impl<'writer, M> FormatFields<'writer> for Mwhere
M: MakeOutput<Writer<'writer>, Result<(), Error>>,
<M as MakeVisitor<Writer<'writer>>>::Visitor: VisitFmt + VisitOutput<Result<(), Error>>,
Source§fn format_fields<R>(
&self,
writer: Writer<'writer>,
fields: R,
) -> Result<(), Error>where
R: RecordFields,
fn format_fields<R>(
&self,
writer: Writer<'writer>,
fields: R,
) -> Result<(), Error>where
R: RecordFields,
Format the provided
fields to the provided Writer, returning a result.Source§fn add_fields(
&self,
current: &'writer mut FormattedFields<Self>,
fields: &Record<'_>,
) -> Result<(), Error>
fn add_fields( &self, current: &'writer mut FormattedFields<Self>, fields: &Record<'_>, ) -> Result<(), Error>
Record additional field(s) on an existing span. 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> ⓘ
Source§impl<T, M> MakeExt<T> for Mwhere
M: MakeVisitor<T> + Sealed<MakeExtMarker<T>>,
impl<T, M> MakeExt<T> for Mwhere
M: MakeVisitor<T> + Sealed<MakeExtMarker<T>>,
Source§impl<T, Out, M> MakeOutput<T, Out> for M
impl<T, Out, M> MakeOutput<T, Out> for M
Source§fn visit_with<F>(&self, target: T, fields: &F) -> Outwhere
F: RecordFields,
fn visit_with<F>(&self, target: T, fields: &F) -> Outwhere
F: RecordFields,
Visits all fields in
fields with a new visitor constructed from
target.