pub enum Refusal {
Show 14 variants
Short,
Form,
Count,
Extension,
Order,
UnknownCatalog,
UnknownIndex,
UnknownRevision,
Capability,
Resource,
Cause,
Leb128,
Trailing,
Pad,
}Expand description
Why a reader refuses a compact descriptor (core §3.3, “Reading”), in the text’s order.
Variants§
Short
No byte, or the bytes end before a field.
Form
CH’s form is not 0, or its tag is not 0.
Count
A count of 0: of entries, or of a list’s items.
Extension
An extension bit is 1.
Order
An entry’s index below the one before it, or a list’s resource not above the one before it.
UnknownCatalog
No held catalog is the one named, or succeeds it (core §8.6).
UnknownIndex
An index at or above the count read through (core §8.6).
UnknownRevision
No held revision of the pair an index names.
Capability
A capability’s bit not the one an earlier bitmap holds for it.
Resource
A resource at or above its revision’s count of resources.
Cause
A cause of 0.
Leb128
A bound refused as a snapshot’s integer is (core §7.5).
Trailing
A byte after the pad.
Pad
A pad bit is 1.
Implementations§
Trait Implementations§
impl Copy for Refusal
impl Eq for Refusal
Source§impl Error for Refusal
impl Error for Refusal
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<ReadRefusal> for Refusal
impl From<ReadRefusal> for Refusal
Source§fn from(r: ReadRefusal) -> Self
fn from(r: ReadRefusal) -> Self
Converts to this type from the input type.
impl StructuralPartialEq for Refusal
Auto Trait Implementations§
impl Forget for Refusal
impl Freeze for Refusal
impl Move for Refusal
impl RefUnwindSafe for Refusal
impl Send for Refusal
impl Sync for Refusal
impl Unpin for Refusal
impl UnsafeUnpin for Refusal
impl UnwindSafe for Refusal
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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