Skip to main content

HandlerContext

Trait HandlerContext 

Source
pub trait HandlerContext: Send {
    // Required methods
    fn load_entity<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 mut self,
        entity_type: &'life1 str,
        id: &'life2 str,
    ) -> Pin<Box<dyn Future<Output = Option<Entity>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
    fn save_entity<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 mut self,
        entity_type: &'life1 str,
        entity: &'life2 Entity,
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
    fn entity_remove(
        &mut self,
        entity_type: &str,
        id: &str,
    ) -> Result<(), Error>;
}

Required Methods§

Source

fn load_entity<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, entity_type: &'life1 str, id: &'life2 str, ) -> Pin<Box<dyn Future<Output = Option<Entity>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Source

fn save_entity<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, entity_type: &'life1 str, entity: &'life2 Entity, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Source

fn entity_remove(&mut self, entity_type: &str, id: &str) -> Result<(), Error>

Implementors§