Struct eos_rs::ffi::type_id

source ·
#[repr(transparent)]
pub struct type_id(_);

Implementations§

source§

impl type_id

This impl provides general metadata about monster types in the game.

source

pub const unsafe fn new(id: u32) -> Self

Returns the ID struct for the type with the given ID.

Safety

The caller must make sure the ID is valid (refers to an existing type), otherwise this is UB.

source

pub const fn id(&self) -> u32

Returns the ID of this type.

source§

impl type_id

source

pub const TYPE_NONE: type_id = _

source§

impl type_id

source

pub const TYPE_NORMAL: type_id = _

source§

impl type_id

source

pub const TYPE_FIRE: type_id = _

source§

impl type_id

source

pub const TYPE_WATER: type_id = _

source§

impl type_id

source

pub const TYPE_GRASS: type_id = _

source§

impl type_id

source§

impl type_id

source

pub const TYPE_ICE: type_id = _

source§

impl type_id

source§

impl type_id

source

pub const TYPE_POISON: type_id = _

source§

impl type_id

source

pub const TYPE_GROUND: type_id = _

source§

impl type_id

source

pub const TYPE_FLYING: type_id = _

source§

impl type_id

source§

impl type_id

source

pub const TYPE_BUG: type_id = _

source§

impl type_id

source

pub const TYPE_ROCK: type_id = _

source§

impl type_id

source

pub const TYPE_GHOST: type_id = _

source§

impl type_id

source

pub const TYPE_DRAGON: type_id = _

source§

impl type_id

source

pub const TYPE_DARK: type_id = _

source§

impl type_id

source

pub const TYPE_STEEL: type_id = _

source§

impl type_id

Trait Implementations§

source§

impl Clone for type_id

source§

fn clone(&self) -> type_id

Returns a copy of the value. Read more
1.0.0§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl From<type_id> for u32

source§

fn from(v: MonsterTypeId) -> Self

Converts to this type from the input type.
source§

impl Hash for type_id

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given [Hasher]. Read more
1.3.0§

fn hash_slice<H>(data: &[Self], state: &mut H)where H: Hasher, Self: Sized,

Feeds a slice of this type into the given [Hasher]. Read more
source§

impl PartialEq<type_id> for type_id

source§

fn eq(&self, other: &type_id) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for type_id

source§

impl StructuralEq for type_id

source§

impl StructuralPartialEq for type_id

Auto Trait Implementations§

§

impl RefUnwindSafe for type_id

§

impl Send for type_id

§

impl Sync for type_id

§

impl Unpin for type_id

§

impl UnwindSafe for type_id

Blanket Implementations§

§

impl<T> Any for Twhere T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Az for T

source§

fn az<Dst>(self) -> Dstwhere T: Cast<Dst>,

Casts the value.
§

impl<T> Borrow<T> for Twhere T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<Src, Dst> CastFrom<Src> for Dstwhere Src: Cast<Dst>,

source§

fn cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> CheckedAs for T

source§

fn checked_as<Dst>(self) -> Option<Dst>where T: CheckedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere Src: CheckedCast<Dst>,

source§

fn checked_cast_from(src: Src) -> Option<Dst>

Casts the value.
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Into<U> for Twhere U: From<T>,

§

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<Src, Dst> LosslessTryInto<Dst> for Srcwhere Dst: LosslessTryFrom<Src>,

source§

fn lossless_try_into(self) -> Option<Dst>

Performs the conversion.
source§

impl<Src, Dst> LossyInto<Dst> for Srcwhere Dst: LossyFrom<Src>,

source§

fn lossy_into(self) -> Dst

Performs the conversion.
source§

impl<T> OverflowingAs for T

source§

fn overflowing_as<Dst>(self) -> (Dst, bool)where T: OverflowingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere Src: OverflowingCast<Dst>,

source§

fn overflowing_cast_from(src: Src) -> (Dst, bool)

Casts the value.
source§

impl<T> Same<T> for T

§

type Output = T

Should always be Self
source§

impl<T> SaturatingAs for T

source§

fn saturating_as<Dst>(self) -> Dstwhere T: SaturatingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere Src: SaturatingCast<Dst>,

source§

fn saturating_cast_from(src: Src) -> Dst

Casts the value.
§

impl<T> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

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

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

Performs the conversion.
§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

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

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> UnwrappedAs for T

source§

fn unwrapped_as<Dst>(self) -> Dstwhere T: UnwrappedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere Src: UnwrappedCast<Dst>,

source§

fn unwrapped_cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> WrappingAs for T

source§

fn wrapping_as<Dst>(self) -> Dstwhere T: WrappingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere Src: WrappingCast<Dst>,

source§

fn wrapping_cast_from(src: Src) -> Dst

Casts the value.