pub struct LogContextMatch {
pub line_number: usize,
pub keyword: String,
pub line: String,
pub before: Vec<String>,
pub after: Vec<String>,
}Expand description
A single keyword match with surrounding context lines.
Fields§
§line_number: usize1-based line number of the matching line.
keyword: StringThe keyword that triggered this match (preserves original casing from the config, not the casing found in the log line).
line: StringThe matching line as-is from the (sanitized) content.
before: Vec<String>Up to LogContextConfig::context_lines lines immediately before
the match, in document order.
after: Vec<String>Up to LogContextConfig::context_lines lines immediately after
the match, in document order.
Trait Implementations§
Source§impl Clone for LogContextMatch
impl Clone for LogContextMatch
Source§fn clone(&self) -> LogContextMatch
fn clone(&self) -> LogContextMatch
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LogContextMatch
impl Debug for LogContextMatch
Auto Trait Implementations§
impl Freeze for LogContextMatch
impl RefUnwindSafe for LogContextMatch
impl Send for LogContextMatch
impl Sync for LogContextMatch
impl Unpin for LogContextMatch
impl UnsafeUnpin for LogContextMatch
impl UnwindSafe for LogContextMatch
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<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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more