pub struct AuditFormatter;Expand description
Formats structured audit log entries based on the configured audit level.
This is the single source of truth for all audit output formats.
Application layer code never calls this directly — only the framework
infrastructure layer uses it inside IntoFuture and MustComment internals.
Implementations§
Source§impl AuditFormatter
impl AuditFormatter
Sourcepub fn format(
module: Module,
level: AuditLevel,
timestamp: &str,
trace_id: &str,
user: &str,
operation: &str,
comment: &str,
elapsed: Duration,
status: &str,
details: &[AuditDetail<'_>],
) -> Option<String>
pub fn format( module: Module, level: AuditLevel, timestamp: &str, trace_id: &str, user: &str, operation: &str, comment: &str, elapsed: Duration, status: &str, details: &[AuditDetail<'_>], ) -> Option<String>
Format an audit log entry. Returns None if the level is Silent.
Sourcepub fn module_tag(module: Module) -> &'static str
pub fn module_tag(module: Module) -> &'static str
Returns the uppercase tag for a module, used in log output.
Auto Trait Implementations§
impl Freeze for AuditFormatter
impl RefUnwindSafe for AuditFormatter
impl Send for AuditFormatter
impl Sync for AuditFormatter
impl Unpin for AuditFormatter
impl UnsafeUnpin for AuditFormatter
impl UnwindSafe for AuditFormatter
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