pub struct ValidationResult {
pub errors: Vec<ValidationError>,
pub warnings: Vec<ValidationWarning>,
}
Expand description
Validation result containing errors and warnings
Fields§
§errors: Vec<ValidationError>
§warnings: Vec<ValidationWarning>
Implementations§
Source§impl ValidationResult
impl ValidationResult
pub fn new() -> Self
pub fn is_valid(&self) -> bool
pub fn has_warnings(&self) -> bool
pub fn add_error(&mut self, error: ValidationError)
pub fn add_warning(&mut self, warning: ValidationWarning)
pub fn errors(&self) -> &[ValidationError]
pub fn warnings(&self) -> &[ValidationWarning]
Trait Implementations§
Source§impl Clone for ValidationResult
impl Clone for ValidationResult
Source§fn clone(&self) -> ValidationResult
fn clone(&self) -> ValidationResult
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 ValidationResult
impl Debug for ValidationResult
Auto Trait Implementations§
impl Freeze for ValidationResult
impl RefUnwindSafe for ValidationResult
impl Send for ValidationResult
impl Sync for ValidationResult
impl Unpin for ValidationResult
impl UnwindSafe for ValidationResult
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