pub struct Finding {
pub id: String,
pub level: FindingLevel,
pub path: String,
pub pos: Option<SourcePos>,
pub message: String,
pub hint: Option<String>,
pub fix: Option<Fix>,
}Expand description
One validation finding — the unit of the interchange format.
Fields§
§id: Stringnamespaced area/.../name, e.g. "structure/section-missing"
level: FindingLevelthe id’s default level from the registry, unless the rule or text constraint sets one
path: Stringthe source document’s file path (ctx.path), for <path>:<line> — not a structural path
pos: Option<SourcePos>omitted for whole-document absence findings
message: Stringwhat is wrong, in a sentence
hint: Option<String>the nearest enclosing description: in the contract; omitted when none is in
scope
fix: Option<Fix>describes only; applying is a separate repair pass
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
impl StructuralPartialEq for Finding
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