pub enum FindingsError {
InvalidAnalyzerId(String),
InvalidWorktreeId(String),
EmptyIdentity,
InvalidIdentityPart(String),
MalformedKey(String),
}Expand description
Errors raised when constructing the identity values this store is keyed by.
These are validation errors, raised by the constructors, so the store never
has to accept an ill-formed key: by the time a value reaches
crate::Store::replace_findings_layer it is already well-formed.
Variants§
InvalidAnalyzerId(String)
An analyzer id broke one of the rules is_valid_analyzer_id enforces:
non-empty, at most MAX_ANALYZER_ID characters, and lowercase
[a-z0-9] plus ., _ and -. The message names the rule that was
actually broken — see analyzer_id_error.
InvalidWorktreeId(String)
A worktree id was empty or contained characters outside [a-z0-9-].
EmptyIdentity
A finding was offered with no identity components at all, so it would have no stable identity across runs.
InvalidIdentityPart(String)
An identity component was empty, over-long, or contained a control character.
MalformedKey(String)
A rendered finding key could not be parsed back (a corrupt row, or a key
produced by something other than FindingKey).
Trait Implementations§
Source§impl Clone for FindingsError
impl Clone for FindingsError
Source§fn clone(&self) -> FindingsError
fn clone(&self) -> FindingsError
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for FindingsError
impl Debug for FindingsError
Source§impl Display for FindingsError
impl Display for FindingsError
impl Eq for FindingsError
Source§impl Error for FindingsError
impl Error for FindingsError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl PartialEq for FindingsError
impl PartialEq for FindingsError
impl StructuralPartialEq for FindingsError
Auto Trait Implementations§
impl Freeze for FindingsError
impl RefUnwindSafe for FindingsError
impl Send for FindingsError
impl Sync for FindingsError
impl Unpin for FindingsError
impl UnsafeUnpin for FindingsError
impl UnwindSafe for FindingsError
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.