pub trait LogStorage {
// Required methods
fn store(&self, event: &AuditEvent) -> DeviceResult<()>;
fn query(&self, criteria: &QueryCriteria) -> DeviceResult<Vec<AuditEvent>>;
fn purge_old_logs(&self, before: SystemTime) -> DeviceResult<usize>;
}Expand description
Log storage trait
Required Methods§
fn store(&self, event: &AuditEvent) -> DeviceResult<()>
fn query(&self, criteria: &QueryCriteria) -> DeviceResult<Vec<AuditEvent>>
fn purge_old_logs(&self, before: SystemTime) -> DeviceResult<usize>
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".