Enum BlockEntityPartError
#[non_exhaustive]pub enum BlockEntityPartError {
VanillaType {
kind: BlockEntityTypeKey,
},
Duplicate {
kind: BlockEntityTypeKey,
part: &'static str,
},
}Expand description
A native Part cannot be attached to this type during registration.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
VanillaType
Vanilla entities do not expose a native Part’s payload.
Fields
§
kind: BlockEntityTypeKeyThe block entity type that was refused.
Duplicate
This Part type is already attached to the entity type.
Fields
§
kind: BlockEntityTypeKeyThe block entity type that was refused.
Trait Implementations§
§impl Clone for BlockEntityPartError
impl Clone for BlockEntityPartError
§fn clone(&self) -> BlockEntityPartError
fn clone(&self) -> BlockEntityPartError
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 more§impl Debug for BlockEntityPartError
impl Debug for BlockEntityPartError
§impl Display for BlockEntityPartError
impl Display for BlockEntityPartError
impl Eq for BlockEntityPartError
§impl Error for BlockEntityPartError
impl Error for BlockEntityPartError
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()
§impl PartialEq for BlockEntityPartError
impl PartialEq for BlockEntityPartError
impl StructuralPartialEq for BlockEntityPartError
Auto Trait Implementations§
impl Freeze for BlockEntityPartError
impl RefUnwindSafe for BlockEntityPartError
impl Send for BlockEntityPartError
impl Sync for BlockEntityPartError
impl Unpin for BlockEntityPartError
impl UnsafeUnpin for BlockEntityPartError
impl UnwindSafe for BlockEntityPartError
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