pub struct Finding {Show 14 fields
pub rule_id: RuleId,
pub severity: Severity,
pub category: Category,
pub message: String,
pub note: Option<String>,
pub fix: Option<String>,
pub file: PathBuf,
pub line: usize,
pub column: usize,
pub end_line: usize,
pub end_column: usize,
pub matched_text: String,
pub confidence: Option<f64>,
pub escalated: bool,
}Expand description
A single finding from scanning a source file.
Fields§
§rule_id: RuleId§severity: Severity§category: Category§message: String§note: Option<String>§fix: Option<String>§file: PathBuf§line: usize§column: usize§end_line: usize§end_column: usize§matched_text: String§confidence: Option<f64>LLM confidence in [0.0, 1.0] for findings confirmed by an AI rule.
None for pure AST findings. Serialized in JSON/SARIF only; the text
output ignores it.
escalated: boolTrue when severity escalation raised this finding from warning to error
because its rule fired repeatedly in the same file. Always serialized so
consumers can filter on escalated == false without a null check.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Finding
impl<'de> Deserialize<'de> for Finding
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Finding
impl RefUnwindSafe for Finding
impl Send for Finding
impl Sync for Finding
impl Unpin for Finding
impl UnsafeUnpin for Finding
impl UnwindSafe for Finding
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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