Skip to main content

QuerySession

Trait QuerySession 

Source
pub trait QuerySession<E: Entity> {
    // Required method
    fn entity_query<'a>(&self) -> Query<'a, E>;
}
Expand description

A session that can start a fluent query for E. Generic read helpers can accept either a store session or the session for the entity’s canister.

Required Methods§

Source

fn entity_query<'a>(&self) -> Query<'a, E>

Build a live query. The builder owns the selected store handle.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<C: CompiledCanister, E: Entity<Store: MountedStore<Canister = C>>> QuerySession<E> for CanisterSession<C>

Source§

impl<E: Entity> QuerySession<E> for DatabaseSession