pub enum LogEvent {
Record(Record),
Continuation(String),
}Expand description
What a LogView’s source sends.
Variants§
Record(Record)
A record.
Continuation(String)
A line that belongs under the last record (see
Assembled::Continuation).
Trait Implementations§
Source§impl From<Record> for LogEvent
A record as an event, so rs-rich-ext’s
ChannelSink can feed a
LogView::source straight from tracing or log:
impl From<Record> for LogEvent
A record as an event, so rs-rich-ext’s
ChannelSink can feed a
LogView::source straight from tracing or log:
use rich_interact::components::{LogEvent, LogView};
use rich_ext::log_stream::{ChannelSink, Record};
let (sink, records) = ChannelSink::<LogEvent>::bounded(1_000);
sink.send(Record::text("started"));
let view = LogView::new().source(records);
// `EventLayer::new(Arc::new(sink))` would send `tracing`'s events.impl StructuralPartialEq for LogEvent
Auto Trait Implementations§
impl Freeze for LogEvent
impl RefUnwindSafe for LogEvent
impl Send for LogEvent
impl Sync for LogEvent
impl Unpin for LogEvent
impl UnsafeUnpin for LogEvent
impl UnwindSafe for LogEvent
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