pub struct ShortIndex(/* private fields */);
Expand description
An optional index used within the model system, that is up to 65000
It can be, effectively, ‘None’ or Some(usize less than 65000)
The purpose is to keep the size of indexed structures small and permit the optional aspect; it is used to index Vec of textures, vertices descriptor sets, etc
It has implementations of From<> to map a usize into a
ShortIndex, and to map from ShortIndex to Option
These extra implementations remove some of the type safety one might have, but make it simpler to use the index
Implementations§
Trait Implementations§
Source§impl Clone for ShortIndex
impl Clone for ShortIndex
Source§fn clone(&self) -> ShortIndex
fn clone(&self) -> ShortIndex
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ShortIndex
impl Debug for ShortIndex
Source§impl Default for ShortIndex
impl Default for ShortIndex
Source§impl From<usize> for ShortIndex
impl From<usize> for ShortIndex
Source§impl PartialEq for ShortIndex
impl PartialEq for ShortIndex
impl Copy for ShortIndex
impl Eq for ShortIndex
impl StructuralPartialEq for ShortIndex
Auto Trait Implementations§
impl Freeze for ShortIndex
impl RefUnwindSafe for ShortIndex
impl Send for ShortIndex
impl Sync for ShortIndex
impl Unpin for ShortIndex
impl UnwindSafe for ShortIndex
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