Trait AbstractChannelInvites

Source
pub trait AbstractChannelInvites: Sync + Send {
    // Required methods
    fn insert_invite<'life0, 'life1, 'async_trait>(
        &'life0 self,
        invite: &'life1 Invite,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn fetch_invite<'life0, 'life1, 'async_trait>(
        &'life0 self,
        code: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<Invite>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn fetch_invites_for_server<'life0, 'life1, 'async_trait>(
        &'life0 self,
        server_id: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<Invite>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn delete_invite<'life0, 'life1, 'async_trait>(
        &'life0 self,
        code: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}

Required Methods§

Source

fn insert_invite<'life0, 'life1, 'async_trait>( &'life0 self, invite: &'life1 Invite, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Insert a new invite into the database

Source

fn fetch_invite<'life0, 'life1, 'async_trait>( &'life0 self, code: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Invite>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Fetch an invite by its id

Source

fn fetch_invites_for_server<'life0, 'life1, 'async_trait>( &'life0 self, server_id: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<Vec<Invite>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Fetch all invites for a server

Source

fn delete_invite<'life0, 'life1, 'async_trait>( &'life0 self, code: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Delete an invite by its id

Implementors§