pub struct AuditReport {
pub summary: AuditSummary,
pub file_results: Vec<FileAuditResult>,
pub issues: Vec<AuditIssue>,
pub recommendations: Vec<Recommendation>,
pub timestamp: DateTime<Utc>,
pub audit_config: AuditReportConfig,
}Available on crate feature
doc-audit only.Expand description
Comprehensive audit report containing all findings and statistics.
Fields§
§summary: AuditSummaryHigh-level summary of the audit results
file_results: Vec<FileAuditResult>Detailed results for each audited file
issues: Vec<AuditIssue>All issues found during the audit
recommendations: Vec<Recommendation>Actionable recommendations for improvements
timestamp: DateTime<Utc>When the audit was performed
audit_config: AuditReportConfigConfiguration used for the audit
Implementations§
Source§impl AuditReport
impl AuditReport
Sourcepub fn new(config: AuditReportConfig) -> AuditReport
pub fn new(config: AuditReportConfig) -> AuditReport
Create a new audit report with the given configuration.
Sourcepub fn add_file_result(&mut self, file_result: FileAuditResult)
pub fn add_file_result(&mut self, file_result: FileAuditResult)
Add a file result to the report.
Sourcepub fn add_issue(&mut self, issue: AuditIssue)
pub fn add_issue(&mut self, issue: AuditIssue)
Add an issue to the report.
Sourcepub fn add_recommendation(&mut self, recommendation: Recommendation)
pub fn add_recommendation(&mut self, recommendation: Recommendation)
Add a recommendation to the report.
Sourcepub fn calculate_summary(&mut self)
pub fn calculate_summary(&mut self)
Calculate and update the summary statistics.
Sourcepub fn issues_by_category(&self) -> HashMap<IssueCategory, Vec<&AuditIssue>>
pub fn issues_by_category(&self) -> HashMap<IssueCategory, Vec<&AuditIssue>>
Get issues by category.
Sourcepub fn issues_by_severity(&self) -> HashMap<IssueSeverity, Vec<&AuditIssue>>
pub fn issues_by_severity(&self) -> HashMap<IssueSeverity, Vec<&AuditIssue>>
Get issues by severity.
Sourcepub fn issues_for_file(&self, file_path: &PathBuf) -> Vec<&AuditIssue>
pub fn issues_for_file(&self, file_path: &PathBuf) -> Vec<&AuditIssue>
Get issues for a specific file.
Trait Implementations§
Source§impl Clone for AuditReport
impl Clone for AuditReport
Source§fn clone(&self) -> AuditReport
fn clone(&self) -> AuditReport
Returns a duplicate of the value. Read more
1.0.0 · 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 AuditReport
impl Debug for AuditReport
Source§impl<'de> Deserialize<'de> for AuditReport
impl<'de> Deserialize<'de> for AuditReport
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<AuditReport, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<AuditReport, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for AuditReport
impl Serialize for AuditReport
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for AuditReport
impl RefUnwindSafe for AuditReport
impl Send for AuditReport
impl Sync for AuditReport
impl Unpin for AuditReport
impl UnwindSafe for AuditReport
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> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request