Trait Retrieve

Source
pub trait Retrieve<S: SearchStrategy>:
    Send
    + Sync
    + DynClone {
    // Required method
    fn retrieve<'life0, 'life1, 'async_trait>(
        &'life0 self,
        search_strategy: &'life1 S,
        query: Query<Pending>,
    ) -> Pin<Box<dyn Future<Output = Result<Query<Retrieved>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;

    // Provided method
    fn name(&self) -> &'static str { ... }
}
Expand description

Can retrieve documents given a SearchStrategy

Required Methods§

Source

fn retrieve<'life0, 'life1, 'async_trait>( &'life0 self, search_strategy: &'life1 S, query: Query<Pending>, ) -> Pin<Box<dyn Future<Output = Result<Query<Retrieved>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Provided Methods§

Source

fn name(&self) -> &'static str

Trait Implementations§

Source§

impl<S: SearchStrategy> Retrieve<S> for Box<dyn Retrieve<S>>

Source§

fn retrieve<'life0, 'life1, 'async_trait>( &'life0 self, search_strategy: &'life1 S, query: Query<Pending>, ) -> Pin<Box<dyn Future<Output = Result<Query<Retrieved>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source§

fn name(&self) -> &'static str

Implementations on Foreign Types§

Source§

impl<S: SearchStrategy> Retrieve<S> for Box<dyn Retrieve<S>>

Source§

fn retrieve<'life0, 'life1, 'async_trait>( &'life0 self, search_strategy: &'life1 S, query: Query<Pending>, ) -> Pin<Box<dyn Future<Output = Result<Query<Retrieved>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source§

fn name(&self) -> &'static str

Implementors§

Source§

impl<S, F> Retrieve<S> for F

Source§

impl<S: SearchStrategy> Retrieve<S> for Arc<dyn Retrieve<S>>