pub enum BlockKindError<'a> {
UnknownOpcode(ARc<str>),
JsonStructure(BlockJsonStructureError),
MissingMandatoryAttr(MandatoryAttrMissingError),
AttrParsing {
location: AttrLocation,
key: &'static str,
error: AttributeParseError<'a>,
},
}Expand description
Specific error for the current block kind’s requirements.
The most interesting one is BlockKindError::AttrParsing as this is produced by individual block attributes (the data associated with a particular block).
Variants§
UnknownOpcode(ARc<str>)
The found opcode is no valid choice for the tried block kind.
Either the wrong kind type was tried, the block opcode is not supported or it is
just invalid. Every opcode that is supported by a variant of
BlockKind is valid.
JsonStructure(BlockJsonStructureError)
MissingMandatoryAttr(MandatoryAttrMissingError)
AttrParsing
Trait Implementations§
Source§impl<'a> Clone for BlockKindError<'a>
impl<'a> Clone for BlockKindError<'a>
Source§fn clone(&self) -> BlockKindError<'a>
fn clone(&self) -> BlockKindError<'a>
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<'a> Debug for BlockKindError<'a>
impl<'a> Debug for BlockKindError<'a>
Source§impl<'a> Display for BlockKindError<'a>
impl<'a> Display for BlockKindError<'a>
Source§impl<'a> Error for BlockKindError<'a>
impl<'a> Error for BlockKindError<'a>
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<'a> From<BlockJsonStructureError> for BlockKindError<'a>
impl<'a> From<BlockJsonStructureError> for BlockKindError<'a>
Source§fn from(source: BlockJsonStructureError) -> Self
fn from(source: BlockJsonStructureError) -> Self
Converts to this type from the input type.
Source§impl<'a> From<MandatoryAttrMissingError> for BlockKindError<'a>
impl<'a> From<MandatoryAttrMissingError> for BlockKindError<'a>
Source§fn from(source: MandatoryAttrMissingError) -> Self
fn from(source: MandatoryAttrMissingError) -> Self
Converts to this type from the input type.
Source§impl<'a> PartialEq for BlockKindError<'a>
impl<'a> PartialEq for BlockKindError<'a>
impl<'a> StructuralPartialEq for BlockKindError<'a>
Auto Trait Implementations§
impl<'a> !Send for BlockKindError<'a>
impl<'a> !Sync for BlockKindError<'a>
impl<'a> Freeze for BlockKindError<'a>
impl<'a> RefUnwindSafe for BlockKindError<'a>
impl<'a> Unpin for BlockKindError<'a>
impl<'a> UnsafeUnpin for BlockKindError<'a>
impl<'a> UnwindSafe for BlockKindError<'a>
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,
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