Struct slog_async::AsyncRecord
source · pub struct AsyncRecord { /* private fields */ }
Expand description
Serialized record.
Implementations§
source§impl AsyncRecord
impl AsyncRecord
sourcepub fn from(record: &Record<'_>, logger_values: &OwnedKVList) -> Self
pub fn from(record: &Record<'_>, logger_values: &OwnedKVList) -> Self
Serializes a Record
and an OwnedKVList
.
sourcepub fn log_to<D: Drain>(self, drain: &D) -> Result<D::Ok, D::Err>
pub fn log_to<D: Drain>(self, drain: &D) -> Result<D::Ok, D::Err>
Writes the record to a Drain
.
sourcepub fn as_record_values(&self, f: impl FnMut(&Record<'_>, &OwnedKVList))
pub fn as_record_values(&self, f: impl FnMut(&Record<'_>, &OwnedKVList))
Deconstruct this AsyncRecord
into a record and OwnedKVList
.
Auto Trait Implementations§
impl !RefUnwindSafe for AsyncRecord
impl Send for AsyncRecord
impl !Sync for AsyncRecord
impl Unpin for AsyncRecord
impl !UnwindSafe for AsyncRecord
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