pub struct NativeSlotable;Trait Implementations§
Source§impl<T: NativelyAtomic> Slotable<T> for NativeSlotable
impl<T: NativelyAtomic> Slotable<T> for NativeSlotable
Source§type Slot = <T as NativelyAtomic>::Atomic
type Slot = <T as NativelyAtomic>::Atomic
Type for slot that contains a single
TSource§type SlotArrayItem = <T as NativelyAtomic>::Atomic
type SlotArrayItem = <T as NativelyAtomic>::Atomic
Type for array/slice element where multiple
Ts are keptSource§fn boxed_uninit_single() -> Box<Self::Slot>
fn boxed_uninit_single() -> Box<Self::Slot>
Create a single slot with no value.
Source§fn read(slot: &Self::Slot, ordering: Ordering) -> MaybeUninit<T>
fn read(slot: &Self::Slot, ordering: Ordering) -> MaybeUninit<T>
Read the slot atomically. Whether a correct
T is read must be determined elsewhere.Source§fn write(slot: &Self::Slot, value: T, ordering: Ordering)
fn write(slot: &Self::Slot, value: T, ordering: Ordering)
Write a single
T into the slot, overwriting (without drop) what was there.Source§fn boxed_uninit_multiple(n: usize) -> Box<[Self::SlotArrayItem]>
fn boxed_uninit_multiple(n: usize) -> Box<[Self::SlotArrayItem]>
Create a slice of slot items capable of holding
n Ts.Source§fn index_in_array(items: &[Self::SlotArrayItem], index: usize) -> &Self::Slot
fn index_in_array(items: &[Self::SlotArrayItem], index: usize) -> &Self::Slot
Given a slice as returned from
Self::boxed_uninit_multiple, access one of the elements.Source§fn create_boxed(value: T) -> Box<Self::Slot>
fn create_boxed(value: T) -> Box<Self::Slot>
Create a single slot with known value.
Auto Trait Implementations§
impl Freeze for NativeSlotable
impl RefUnwindSafe for NativeSlotable
impl Send for NativeSlotable
impl Sync for NativeSlotable
impl Unpin for NativeSlotable
impl UnsafeUnpin for NativeSlotable
impl UnwindSafe for NativeSlotable
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