pub struct PostgresTeamRepository { /* private fields */ }Expand description
PostgreSQL team repository
Implementations§
Trait Implementations§
Source§impl TeamRepository for PostgresTeamRepository
impl TeamRepository for PostgresTeamRepository
Source§fn create<'life0, 'async_trait>(
&'life0 self,
_team: Team,
) -> Pin<Box<dyn Future<Output = Result<Team>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create<'life0, 'async_trait>(
&'life0 self,
_team: Team,
) -> Pin<Box<dyn Future<Output = Result<Team>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create a new team
Source§fn get<'life0, 'async_trait>(
&'life0 self,
_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Team>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get<'life0, 'async_trait>(
&'life0 self,
_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Team>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get a team by ID
Source§fn get_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Team>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Team>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get a team by name
Source§fn update<'life0, 'async_trait>(
&'life0 self,
_team: Team,
) -> Pin<Box<dyn Future<Output = Result<Team>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn update<'life0, 'async_trait>(
&'life0 self,
_team: Team,
) -> Pin<Box<dyn Future<Output = Result<Team>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Update an existing team
Source§fn delete<'life0, 'async_trait>(
&'life0 self,
_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete<'life0, 'async_trait>(
&'life0 self,
_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Delete a team by ID
Source§fn list<'life0, 'async_trait>(
&'life0 self,
_offset: u32,
_limit: u32,
) -> Pin<Box<dyn Future<Output = Result<(Vec<Team>, u64)>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list<'life0, 'async_trait>(
&'life0 self,
_offset: u32,
_limit: u32,
) -> Pin<Box<dyn Future<Output = Result<(Vec<Team>, u64)>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
List all teams with pagination
Source§fn count<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn count<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Count total teams
Source§fn add_member<'life0, 'async_trait>(
&'life0 self,
_member: TeamMember,
) -> Pin<Box<dyn Future<Output = Result<TeamMember>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn add_member<'life0, 'async_trait>(
&'life0 self,
_member: TeamMember,
) -> Pin<Box<dyn Future<Output = Result<TeamMember>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Add a member to a team
Source§fn get_member<'life0, 'async_trait>(
&'life0 self,
_team_id: Uuid,
_user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<TeamMember>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_member<'life0, 'async_trait>(
&'life0 self,
_team_id: Uuid,
_user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<TeamMember>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get a team member
Source§fn update_member_role<'life0, 'async_trait>(
&'life0 self,
_team_id: Uuid,
_user_id: Uuid,
_role: TeamRole,
) -> Pin<Box<dyn Future<Output = Result<TeamMember>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn update_member_role<'life0, 'async_trait>(
&'life0 self,
_team_id: Uuid,
_user_id: Uuid,
_role: TeamRole,
) -> Pin<Box<dyn Future<Output = Result<TeamMember>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Update a team member’s role
Source§fn remove_member<'life0, 'async_trait>(
&'life0 self,
_team_id: Uuid,
_user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn remove_member<'life0, 'async_trait>(
&'life0 self,
_team_id: Uuid,
_user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Remove a member from a team
Auto Trait Implementations§
impl !RefUnwindSafe for PostgresTeamRepository
impl !UnwindSafe for PostgresTeamRepository
impl Freeze for PostgresTeamRepository
impl Send for PostgresTeamRepository
impl Sync for PostgresTeamRepository
impl Unpin for PostgresTeamRepository
impl UnsafeUnpin for PostgresTeamRepository
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> BudgetAwareRouting for T
impl<T> BudgetAwareRouting for T
Source§fn filter_by_budget(
&self,
providers: Vec<String>,
budget_router: &BudgetAwareRouter,
) -> Vec<String>
fn filter_by_budget( &self, providers: Vec<String>, budget_router: &BudgetAwareRouter, ) -> Vec<String>
Filter providers based on budget availability
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreCreates a shared type from an unshared type.