Skip to main content

ValidationErrorKind

Enum ValidationErrorKind 

Source
pub enum ValidationErrorKind {
Show 23 variants DuplicateName { namespace: NameNamespace, name: String, }, UnknownType { name: String, }, RecursiveType { cycle: Vec<String>, }, TypeMismatch { expected: ValueKind, actual: ValueKind, }, UnknownField { name: String, }, MissingField { name: String, }, UnknownCase { name: String, }, MissingUnionPayload, UnexpectedUnionPayload, UnknownParameter { name: String, }, MissingParameter { name: String, }, UnknownOperation { name: String, }, IntegerOutOfRange { value: i64, }, NonFiniteNumber, BytesInJson, InvalidObjectName { name: String, }, DuplicateInterface { reference: String, }, InvalidPath { path: String, }, ObjectNameMismatch { expected: String, actual: String, }, InconsistentObjectObservation { reference: String, }, ChildrenMissingBeforeDepth { depth: u32, }, ChildrenAtDepthBoundary { depth: u32, }, InterfaceResponseMismatch { expected: String, actual: String, },
}
Expand description

Machine-readable reason why logical protocol validation failed.

Variants§

§

DuplicateName

A name occurred more than once in one namespace.

Fields

§namespace: NameNamespace

Namespace containing the duplicate.

§name: String

Duplicate name.

§

UnknownType

A named type was not declared in the descriptor.

Fields

§name: String

Missing descriptor-local type name.

§

RecursiveType

Named declarations form a recursive cycle.

Fields

§cycle: Vec<String>

Cycle in traversal order, with the starting name repeated last.

§

TypeMismatch

A value has the wrong structural kind.

Fields

§expected: ValueKind

Expected kind.

§actual: ValueKind

Actual kind.

§

UnknownField

A record value contains an undeclared field.

Fields

§name: String

Unknown field name.

§

MissingField

A record value omitted a required field.

Fields

§name: String

Missing field name.

§

UnknownCase

An enum or union selected an undeclared case.

Fields

§name: String

Unknown case name.

§

MissingUnionPayload

A payload-bearing union case omitted value.

§

UnexpectedUnionPayload

A payload-free union case supplied value.

§

UnknownParameter

An operation call contains an undeclared argument.

Fields

§name: String

Unknown parameter name.

§

MissingParameter

An operation call omitted a required argument.

Fields

§name: String

Missing parameter name.

§

UnknownOperation

An operation is not declared by the descriptor.

Fields

§name: String

Unknown operation name.

§

IntegerOutOfRange

An integer is outside the interoperable safe range.

Fields

§value: i64

Rejected integer.

§

NonFiniteNumber

A numeric value is NaN or infinite.

§

BytesInJson

A JSON-interpreted value tree contains protocol bytes.

§

InvalidObjectName

An object name is not a valid root or non-root path segment.

Fields

§name: String

Rejected object name.

§

DuplicateInterface

An object’s ordered interface set contains a duplicate.

Fields

§reference: String

Duplicate opaque interface reference.

§

InvalidPath

A string is not a canonical absolute Worldspace path.

Fields

§path: String

Rejected path.

§

ObjectNameMismatch

An object name does not match the path where it was observed.

Fields

§expected: String

Name required by the observation path.

§actual: String

Name supplied by the object.

§

InconsistentObjectObservation

Equivalent ref/validator observations disagree on object representation.

Fields

§reference: String

Shared opaque object reference.

§

ChildrenMissingBeforeDepth

An observation omitted children before reaching the requested depth.

Fields

§depth: u32

Node depth where children were required.

§

ChildrenAtDepthBoundary

An observation included children at the requested depth boundary.

Fields

§depth: u32

Boundary depth where children must be unobserved.

§

InterfaceResponseMismatch

A response refers to a different interface than its request.

Fields

§expected: String

Requested opaque reference.

§actual: String

Returned opaque reference.

Trait Implementations§

Source§

impl Clone for ValidationErrorKind

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for ValidationErrorKind

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for ValidationErrorKind

Source§

impl PartialEq for ValidationErrorKind

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for ValidationErrorKind

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.