pub struct Redactions(/* private fields */);Expand description
Known secret values, replaced by *** in every rendered string.
Implementations§
Source§impl Redactions
impl Redactions
Sourcepub fn new(values: impl IntoIterator<Item = String>) -> Self
pub fn new(values: impl IntoIterator<Item = String>) -> Self
Redact these values (empty values are ignored — nothing to leak).
Sourcepub fn apply_event(&self, event: &Event) -> Event
pub fn apply_event(&self, event: &Event) -> Event
The event with every string field redacted. The match is exhaustive on purpose: adding an event variant forces a redaction decision here, so the invariant (ADR-0005: secrets reach no sink) cannot silently erode as the schema grows.
Trait Implementations§
Source§impl Clone for Redactions
impl Clone for Redactions
Source§fn clone(&self) -> Redactions
fn clone(&self) -> Redactions
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 Redactions
impl Debug for Redactions
Source§impl Default for Redactions
impl Default for Redactions
Source§fn default() -> Redactions
fn default() -> Redactions
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for Redactions
impl RefUnwindSafe for Redactions
impl Send for Redactions
impl Sync for Redactions
impl Unpin for Redactions
impl UnsafeUnpin for Redactions
impl UnwindSafe for Redactions
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