pub struct ReportOptions {
pub use_colors: bool,
pub show_context: bool,
pub show_suggestions: bool,
pub max_violations: Option<usize>,
pub min_severity: Option<Severity>,
}Expand description
Options for customizing report output
Fields§
§use_colors: boolWhether to use colored output (for human format)
show_context: boolWhether to show context lines around violations
show_suggestions: boolWhether to show violation suggestions
max_violations: Option<usize>Maximum number of violations to include
min_severity: Option<Severity>Minimum severity level to include
Implementations§
Source§impl ReportOptions
impl ReportOptions
Sourcepub fn validate(&self) -> GuardianResult<()>
pub fn validate(&self) -> GuardianResult<()>
Validate options consistency
Architecture Principle: Domain objects validate their own invariants
Sourcepub fn is_optimized_for(&self, format: OutputFormat) -> bool
pub fn is_optimized_for(&self, format: OutputFormat) -> bool
Check if these options are optimized for the given format
Sourcepub fn optimized_for(format: OutputFormat) -> Self
pub fn optimized_for(format: OutputFormat) -> Self
Create optimized options for a specific format
Trait Implementations§
Source§impl Clone for ReportOptions
impl Clone for ReportOptions
Source§fn clone(&self) -> ReportOptions
fn clone(&self) -> ReportOptions
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 ReportOptions
impl Debug for ReportOptions
Auto Trait Implementations§
impl Freeze for ReportOptions
impl RefUnwindSafe for ReportOptions
impl Send for ReportOptions
impl Sync for ReportOptions
impl Unpin for ReportOptions
impl UnwindSafe for ReportOptions
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