Trait soapy::Soapy

source ·
pub unsafe trait Soapy: AsSoaRef<Item = Self> {
    type Raw: SoaRaw<Item = Self>;
    type Deref: ?Sized + SoaDeref<Item = Self>;
    type Ref<'a>: Copy + Clone + AsSoaRef<Item = Self>
       where Self: 'a;
    type RefMut<'a>: AsSoaRef<Item = Self>
       where Self: 'a;
    type Array<const N: usize>: SoaArray<Item = Self>;
    type Slices<'a>
       where Self: 'a;
    type SlicesMut<'a>
       where Self: 'a;
}
Expand description

Provides Soa compatibility.

§Safety

Soapy::Deref mut be #[repr(transparent)] with Slice<Self::Raw>. This trait should be derived using the derive macro.

Required Associated Types§

source

type Raw: SoaRaw<Item = Self>

Implements internal, unsafe, low-level routines used by Soa

source

type Deref: ?Sized + SoaDeref<Item = Self>

Slice dereferences to this type to provide getters for the individual fields as slices.

source

type Ref<'a>: Copy + Clone + AsSoaRef<Item = Self> where Self: 'a

A reference to an element of a Slice.

For each field with type T, this type has a field with type &T.

source

type RefMut<'a>: AsSoaRef<Item = Self> where Self: 'a

A reference to an element of a Slice.

For each field with type T, this type has a field with type &mut T.

source

type Array<const N: usize>: SoaArray<Item = Self>

The SoA array type.

For each field with type T, this type has a field with type [T; N].

source

type Slices<'a> where Self: 'a

The slices that make up a Slice.

For each field with type T, this type has a field with type &[T].

source

type SlicesMut<'a> where Self: 'a

The mutable slices that make up a Slice.

For each field with type T, this type has a field with type &mut [T].

Object Safety§

This trait is not object safe.

Implementors§