pub struct ValidationError { /* private fields */ }Expand description
A structured validation issue.
Implementations§
Source§impl ValidationError
impl ValidationError
Sourcepub fn unsupported_op(
backend: &'static str,
op_id: &Arc<str>,
node_index: usize,
) -> Self
pub fn unsupported_op( backend: &'static str, op_id: &Arc<str>, node_index: usize, ) -> Self
Build an unsupported-operation diagnostic for backend capability checks.
Sourcepub fn code(&self) -> &ValidationCode
pub fn code(&self) -> &ValidationCode
Stable rule identity.
Sourcepub const fn phase(&self) -> ValidationPhase
pub const fn phase(&self) -> ValidationPhase
Rule-owning validation phase.
Sourcepub const fn location(&self) -> &ValidationLocation
pub const fn location(&self) -> &ValidationLocation
Typed program location.
Sourcepub fn corrective_action(&self) -> &str
pub fn corrective_action(&self) -> &str
Corrective action.
Sourcepub const fn retry(&self) -> RetryClass
pub const fn retry(&self) -> RetryClass
Retry policy.
Sourcepub fn trace_event(&self) -> ValidationTraceEvent
pub fn trace_event(&self) -> ValidationTraceEvent
Return the trace event for this emission.
Sourcepub fn diagnostic(&self) -> Diagnostic
pub fn diagnostic(&self) -> Diagnostic
Project the issue into the shared diagnostic protocol.
Trait Implementations§
Source§impl Clone for ValidationError
impl Clone for ValidationError
Source§fn clone(&self) -> ValidationError
fn clone(&self) -> ValidationError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 ValidationError
impl Debug for ValidationError
Source§impl<'de> Deserialize<'de> for ValidationError
impl<'de> Deserialize<'de> for ValidationError
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
Source§impl Display for ValidationError
impl Display for ValidationError
impl Eq for ValidationError
Source§impl Error for ValidationError
impl Error for ValidationError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<&ValidationError> for Diagnostic
impl From<&ValidationError> for Diagnostic
Source§fn from(issue: &ValidationError) -> Self
fn from(issue: &ValidationError) -> Self
Converts to this type from the input type.
Source§impl From<ValidationError> for Diagnostic
impl From<ValidationError> for Diagnostic
Source§fn from(issue: ValidationError) -> Self
fn from(issue: ValidationError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for ValidationError
impl PartialEq for ValidationError
Source§impl Serialize for ValidationError
impl Serialize for ValidationError
impl StructuralPartialEq for ValidationError
Auto Trait Implementations§
impl Freeze for ValidationError
impl RefUnwindSafe for ValidationError
impl Send for ValidationError
impl Sync for ValidationError
impl Unpin for ValidationError
impl UnsafeUnpin for ValidationError
impl UnwindSafe for ValidationError
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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
Compare self to
key and return true if they are equal.