pub enum LinksCodecError {
MissingLink(LinkId),
ExpectedObject {
link: LinkId,
},
MalformedObject {
object: LinkId,
reason: String,
},
UnexpectedType {
object: LinkId,
expected: String,
actual: Option<String>,
},
MissingField {
object: LinkId,
field: String,
},
DuplicateField {
object: LinkId,
field: String,
},
MalformedField {
field: LinkId,
reason: String,
},
InvalidLiteral {
object: LinkId,
type_name: String,
value: Option<String>,
reason: String,
},
CacheTypeMismatch {
type_name: String,
},
}Expand description
Error returned while decoding Rust values from links.
Variants§
MissingLink(LinkId)
A referenced link id is absent from the network.
ExpectedObject
The link exists but is not an object instance.
MalformedObject
An object instance does not carry the expected self/type references.
UnexpectedType
An object type did not match the requested Rust type.
MissingField
A required field is missing.
DuplicateField
A field expected to be singular has multiple values.
MalformedField
A field relation is structurally invalid.
InvalidLiteral
A literal link is missing or malformed.
CacheTypeMismatch
A cached object had an unexpected Rust type.
Trait Implementations§
Source§impl Clone for LinksCodecError
impl Clone for LinksCodecError
Source§fn clone(&self) -> LinksCodecError
fn clone(&self) -> LinksCodecError
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 LinksCodecError
impl Debug for LinksCodecError
Source§impl Display for LinksCodecError
impl Display for LinksCodecError
Source§impl Error for LinksCodecError
impl Error for LinksCodecError
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 PartialEq for LinksCodecError
impl PartialEq for LinksCodecError
impl Eq for LinksCodecError
impl StructuralPartialEq for LinksCodecError
Auto Trait Implementations§
impl Freeze for LinksCodecError
impl RefUnwindSafe for LinksCodecError
impl Send for LinksCodecError
impl Sync for LinksCodecError
impl Unpin for LinksCodecError
impl UnsafeUnpin for LinksCodecError
impl UnwindSafe for LinksCodecError
Blanket Implementations§
§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
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§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Returns the layout of the type.