Trait Query

Source
pub trait Query {
    type Item<'a>;
}
Expand description

A collection of component types to fetch from a World

The interface of this trait is a private implementation detail.

Required Associated Types§

Source

type Item<'a>

Type of results yielded by the query

This is usually the same type as the query itself, except with an appropriate lifetime.

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.

Implementations on Foreign Types§

Source§

impl Query for ()

Source§

type Item<'q> = ()

Source§

impl<'a, T> Query for &'a T
where T: Component,

Source§

type Item<'q> = &'q T

Source§

impl<'a, T> Query for &'a mut T
where T: Component,

Source§

impl<A> Query for (A,)
where A: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>,)

Source§

impl<A, B> Query for (A, B)
where A: Query, B: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>)

Source§

impl<A, B, C> Query for (A, B, C)
where A: Query, B: Query, C: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>)

Source§

impl<A, B, C, D> Query for (A, B, C, D)
where A: Query, B: Query, C: Query, D: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>)

Source§

impl<A, B, C, D, E> Query for (A, B, C, D, E)
where A: Query, B: Query, C: Query, D: Query, E: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F> Query for (A, B, C, D, E, F)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G> Query for (A, B, C, D, E, F, G)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G, H> Query for (A, B, C, D, E, F, G, H)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query, H: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>, <H as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G, H, I> Query for (A, B, C, D, E, F, G, H, I)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query, H: Query, I: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>, <H as Query>::Item<'q>, <I as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G, H, I, J> Query for (A, B, C, D, E, F, G, H, I, J)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query, H: Query, I: Query, J: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>, <H as Query>::Item<'q>, <I as Query>::Item<'q>, <J as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K> Query for (A, B, C, D, E, F, G, H, I, J, K)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query, H: Query, I: Query, J: Query, K: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>, <H as Query>::Item<'q>, <I as Query>::Item<'q>, <J as Query>::Item<'q>, <K as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L> Query for (A, B, C, D, E, F, G, H, I, J, K, L)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query, H: Query, I: Query, J: Query, K: Query, L: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>, <H as Query>::Item<'q>, <I as Query>::Item<'q>, <J as Query>::Item<'q>, <K as Query>::Item<'q>, <L as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M> Query for (A, B, C, D, E, F, G, H, I, J, K, L, M)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query, H: Query, I: Query, J: Query, K: Query, L: Query, M: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>, <H as Query>::Item<'q>, <I as Query>::Item<'q>, <J as Query>::Item<'q>, <K as Query>::Item<'q>, <L as Query>::Item<'q>, <M as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N> Query for (A, B, C, D, E, F, G, H, I, J, K, L, M, N)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query, H: Query, I: Query, J: Query, K: Query, L: Query, M: Query, N: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>, <H as Query>::Item<'q>, <I as Query>::Item<'q>, <J as Query>::Item<'q>, <K as Query>::Item<'q>, <L as Query>::Item<'q>, <M as Query>::Item<'q>, <N as Query>::Item<'q>)

Source§

impl<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O> Query for (A, B, C, D, E, F, G, H, I, J, K, L, M, N, O)
where A: Query, B: Query, C: Query, D: Query, E: Query, F: Query, G: Query, H: Query, I: Query, J: Query, K: Query, L: Query, M: Query, N: Query, O: Query,

Source§

type Item<'q> = (<A as Query>::Item<'q>, <B as Query>::Item<'q>, <C as Query>::Item<'q>, <D as Query>::Item<'q>, <E as Query>::Item<'q>, <F as Query>::Item<'q>, <G as Query>::Item<'q>, <H as Query>::Item<'q>, <I as Query>::Item<'q>, <J as Query>::Item<'q>, <K as Query>::Item<'q>, <L as Query>::Item<'q>, <M as Query>::Item<'q>, <N as Query>::Item<'q>, <O as Query>::Item<'q>)

Source§

impl<T> Query for Option<T>
where T: Query,

Source§

type Item<'q> = Option<<T as Query>::Item<'q>>

Implementors§

Source§

impl<L, R> Query for Or<L, R>
where L: Query, R: Query,

Source§

type Item<'q> = Or<<L as Query>::Item<'q>, <R as Query>::Item<'q>>

Source§

impl<Q> Query for Satisfies<Q>
where Q: Query,

Source§

type Item<'q> = bool

Source§

impl<Q, R> Query for With<Q, R>
where Q: Query, R: Query,

Source§

type Item<'q> = <Q as Query>::Item<'q>

Source§

impl<Q, R> Query for Without<Q, R>
where Q: Query, R: Query,

Source§

type Item<'q> = <Q as Query>::Item<'q>