pub trait AbstractServerMembers: Sync + Send {
    // Required methods
    fn insert_member<'life0, 'life1, 'async_trait>(
        &'life0 self,
        member: &'life1 Member
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn fetch_member<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        server_id: &'life1 str,
        user_id: &'life2 str
    ) -> Pin<Box<dyn Future<Output = Result<Member>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
    fn fetch_all_members<'a, 'life0, 'life1, 'async_trait>(
        &'life0 self,
        server_id: &'life1 str
    ) -> Pin<Box<dyn Future<Output = Result<Vec<Member>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'a: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn fetch_all_memberships<'a, 'life0, 'life1, 'async_trait>(
        &'life0 self,
        user_id: &'life1 str
    ) -> Pin<Box<dyn Future<Output = Result<Vec<Member>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'a: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn fetch_members<'a, 'life0, 'life1, 'async_trait>(
        &'life0 self,
        server_id: &'life1 str,
        ids: &'a [String]
    ) -> Pin<Box<dyn Future<Output = Result<Vec<Member>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'a: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn fetch_member_count<'life0, 'life1, 'async_trait>(
        &'life0 self,
        server_id: &'life1 str
    ) -> Pin<Box<dyn Future<Output = Result<usize>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn fetch_server_count<'life0, 'life1, 'async_trait>(
        &'life0 self,
        user_id: &'life1 str
    ) -> Pin<Box<dyn Future<Output = Result<usize>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn update_member<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        id: &'life1 MemberCompositeKey,
        partial: &'life2 PartialMember,
        remove: Vec<FieldsMember>
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait;
    fn delete_member<'life0, 'life1, 'async_trait>(
        &'life0 self,
        id: &'life1 MemberCompositeKey
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}

Required Methods§

source

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

Insert a new server member into the database

source

fn fetch_member<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, server_id: &'life1 str, user_id: &'life2 str ) -> Pin<Box<dyn Future<Output = Result<Member>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Fetch a server member by their id

source

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

Fetch all members in a server

source

fn fetch_all_memberships<'a, 'life0, 'life1, 'async_trait>( &'life0 self, user_id: &'life1 str ) -> Pin<Box<dyn Future<Output = Result<Vec<Member>>> + Send + 'async_trait>>
where Self: 'async_trait, 'a: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Fetch all memberships for a user

source

fn fetch_members<'a, 'life0, 'life1, 'async_trait>( &'life0 self, server_id: &'life1 str, ids: &'a [String] ) -> Pin<Box<dyn Future<Output = Result<Vec<Member>>> + Send + 'async_trait>>
where Self: 'async_trait, 'a: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Fetch multiple members by their ids

source

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

Fetch member count of a server

source

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

Fetch server count of a user

source

fn update_member<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, id: &'life1 MemberCompositeKey, partial: &'life2 PartialMember, remove: Vec<FieldsMember> ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Update information for a server member

source

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

Delete a server member by their id

Implementors§