pub enum SafetyIssue {
ContainsNaN {
count: usize,
locations: Vec<String>,
},
ContainsInfinity {
count: usize,
locations: Vec<String>,
},
OutOfRange {
min_allowed: f64,
max_allowed: f64,
violations: usize,
},
InvalidShape {
expected: Vec<usize>,
actual: Vec<usize>,
},
EmptyData,
SuspiciousPattern {
pattern: String,
description: String,
},
UnsafeCharacters {
characters: Vec<char>,
},
ExceedsLimits {
size: usize,
limit: usize,
},
}Expand description
Types of safety issues that can be found in input data
Variants§
ContainsNaN
Contains NaN values
ContainsInfinity
Contains infinite values
OutOfRange
Values outside acceptable range
InvalidShape
Array shape is invalid
EmptyData
Empty data where data is required
SuspiciousPattern
Suspicious patterns that might indicate attacks
UnsafeCharacters
String contains potentially dangerous characters
ExceedsLimits
Data size exceeds limits
Trait Implementations§
Source§impl Clone for SafetyIssue
impl Clone for SafetyIssue
Source§fn clone(&self) -> SafetyIssue
fn clone(&self) -> SafetyIssue
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 SafetyIssue
impl Debug for SafetyIssue
Source§impl PartialEq for SafetyIssue
impl PartialEq for SafetyIssue
impl StructuralPartialEq for SafetyIssue
Auto Trait Implementations§
impl Freeze for SafetyIssue
impl RefUnwindSafe for SafetyIssue
impl Send for SafetyIssue
impl Sync for SafetyIssue
impl Unpin for SafetyIssue
impl UnwindSafe for SafetyIssue
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> 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