MapMut

Enum MapMut 

Source
pub enum MapMut<'s, C: ConfigMut> {
Show 13 variants End(&'s mut ()), Byte(&'s mut i8), Short(&'s mut I16<C::ByteOrder>), Int(&'s mut I32<C::ByteOrder>), Long(&'s mut I64<C::ByteOrder>), Float(&'s mut F32<C::ByteOrder>), Double(&'s mut F64<C::ByteOrder>), ByteArray(VecMut<'s, i8>), String(StringMut<'s>), List(C::ListMut<'s>), Compound(C::CompoundMut<'s>), IntArray(VecMut<'s, I32<C::ByteOrder>>), LongArray(VecMut<'s, I64<C::ByteOrder>>),
}
Expand description

An owned variant for mapping mutable NBT values.

This enum is used by the ValueMut::map method to consume and transform mutable NBT values. Each variant contains the corresponding mutable NBT type.

§Type Parameters

  • 's - Lifetime of the source data
  • C - Configuration trait

Variants§

§

End(&'s mut ())

§

Byte(&'s mut i8)

§

Short(&'s mut I16<C::ByteOrder>)

§

Int(&'s mut I32<C::ByteOrder>)

§

Long(&'s mut I64<C::ByteOrder>)

§

Float(&'s mut F32<C::ByteOrder>)

§

Double(&'s mut F64<C::ByteOrder>)

§

ByteArray(VecMut<'s, i8>)

§

String(StringMut<'s>)

§

List(C::ListMut<'s>)

§

Compound(C::CompoundMut<'s>)

§

IntArray(VecMut<'s, I32<C::ByteOrder>>)

§

LongArray(VecMut<'s, I64<C::ByteOrder>>)

Auto Trait Implementations§

§

impl<'s, C> Freeze for MapMut<'s, C>
where <C as ConfigMut>::ListMut<'s>: Freeze, <C as ConfigMut>::CompoundMut<'s>: Freeze,

§

impl<'s, C> RefUnwindSafe for MapMut<'s, C>
where <C as ConfigMut>::ListMut<'s>: RefUnwindSafe, <C as ConfigMut>::CompoundMut<'s>: RefUnwindSafe, <C as ConfigRef>::ByteOrder: RefUnwindSafe,

§

impl<'s, C> Send for MapMut<'s, C>

§

impl<'s, C> Sync for MapMut<'s, C>

§

impl<'s, C> Unpin for MapMut<'s, C>
where <C as ConfigMut>::ListMut<'s>: Unpin, <C as ConfigMut>::CompoundMut<'s>: Unpin, <C as ConfigRef>::ByteOrder: Unpin,

§

impl<'s, C> !UnwindSafe for MapMut<'s, C>

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> 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, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.