ResourceQuery

Trait ResourceQuery 

Source
pub trait ResourceQuery<'a> {
    type Answer;

    // Required methods
    fn has_resources(&self, rss: &Resources) -> bool;
    fn borrow_resources(&self, rss: &'a Resources) -> Option<Self::Answer>;
}
Expand description

Query for resources and borrow them

Required Associated Types§

Source

type Answer

Type of the answer to a query, should be a tuple

Required Methods§

Source

fn has_resources(&self, rss: &Resources) -> bool

Query if the resources exist

Source

fn borrow_resources(&self, rss: &'a Resources) -> Option<Self::Answer>

Query and borrow the resources

Implementors§

Source§

impl<'a, T1: ResourceTrait> ResourceQuery<'a> for T1