pub trait WorldQuery {
type StaticType: 'static;
type Fetch<'w>: Copy;
type Item<'w>;
type Slice<'w>;
// Required methods
unsafe fn fetch_raw<'w>(
arch: &Archetype,
system_tick: u32,
) -> Option<Self::Fetch<'w>>;
fn check_aliasing(types: &mut Vec<(TypeId, bool)>);
fn matches_archetype(arch: &Archetype) -> bool;
unsafe fn get_item<'w>(fetch: Self::Fetch<'w>, row: usize) -> Self::Item<'w>;
unsafe fn filter_row<'w>(
fetch: Self::Fetch<'w>,
row: usize,
system_tick: u32,
) -> bool;
unsafe fn get_slice<'w>(
fetch: Self::Fetch<'w>,
len: usize,
) -> Self::Slice<'w>;
}Required Associated Types§
Required Methods§
unsafe fn fetch_raw<'w>( arch: &Archetype, system_tick: u32, ) -> Option<Self::Fetch<'w>>
fn check_aliasing(types: &mut Vec<(TypeId, bool)>)
fn matches_archetype(arch: &Archetype) -> bool
unsafe fn get_item<'w>(fetch: Self::Fetch<'w>, row: usize) -> Self::Item<'w>
unsafe fn filter_row<'w>( fetch: Self::Fetch<'w>, row: usize, system_tick: u32, ) -> bool
unsafe fn get_slice<'w>(fetch: Self::Fetch<'w>, len: usize) -> Self::Slice<'w>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.