pub struct SaveId(pub u64);Expand description
An entity’s id in saves, which stays the same from one run to the
next, unlike its Entity. Saves (roadmap M9.4) store only
entities that have one.
Tuple Fields§
§0: u64Trait Implementations§
impl Component for SaveId
impl Copy for SaveId
impl Eq for SaveId
Source§impl FromValue for SaveId
impl FromValue for SaveId
Source§const TYPE_NAME: &'static str = "SaveId"
const TYPE_NAME: &'static str = "SaveId"
The type’s name, as
Reflect::type_name gives it.Source§fn from_value(
value: &Value,
cx: &mut ReflectContext<'_>,
) -> Result<Self, ReflectError>
fn from_value( value: &Value, cx: &mut ReflectContext<'_>, ) -> Result<Self, ReflectError>
Makes a value of the type from
value. Read moreSource§impl Ord for SaveId
impl Ord for SaveId
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialOrd for SaveId
impl PartialOrd for SaveId
Source§impl Reflect for SaveId
impl Reflect for SaveId
Source§fn type_name(&self) -> &'static str
fn type_name(&self) -> &'static str
The type’s name: for the macros’ types, its name as written
(
Health), which prefabs and saves use.Source§fn kind(&self) -> ReflectKind
fn kind(&self) -> ReflectKind
What sort of value it is.
Source§fn fields(&self) -> &'static [FieldInfo]
fn fields(&self) -> &'static [FieldInfo]
The fields of a struct, in order; none for other kinds.
Source§fn variants(&self) -> &'static [&'static str]
fn variants(&self) -> &'static [&'static str]
The variants of an enum, by name, in order, as data writes them:
what an inspector offers to pick from. None for other kinds, and by
default:
reflect_enum! gives its enum’s.Source§fn field(&self, index: usize) -> Option<&dyn Reflect>
fn field(&self, index: usize) -> Option<&dyn Reflect>
Field
index of a struct, or element index of a list or an
option.Source§fn field_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>
fn field_mut(&mut self, index: usize) -> Option<&mut dyn Reflect>
Field or element
index, to change it.Source§fn apply_value(
&mut self,
value: &Value,
cx: &mut ReflectContext<'_>,
) -> Result<(), ReflectError>
fn apply_value( &mut self, value: &Value, cx: &mut ReflectContext<'_>, ) -> Result<(), ReflectError>
Sets the value from
value. A field that value does not name
keeps its value; a field it names that the type does not have is a
warning. On an error, what was applied before it stays applied. Read moreimpl StructuralPartialEq for SaveId
Auto Trait Implementations§
impl Forget for SaveId
impl Freeze for SaveId
impl Move for SaveId
impl RefUnwindSafe for SaveId
impl Send for SaveId
impl Sync for SaveId
impl Unpin for SaveId
impl UnsafeUnpin for SaveId
impl UnwindSafe for SaveId
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