pub struct MemoryStore { /* private fields */ }Implementations§
Source§impl MemoryStore
impl MemoryStore
Trait Implementations§
Source§impl ApiKeyRepository for MemoryStore
impl ApiKeyRepository for MemoryStore
fn create<'life0, 'async_trait>(
&'life0 self,
data: CreateApiKey,
) -> Pin<Box<dyn Future<Output = Result<ApiKey>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_hash<'life0, 'life1, 'async_trait>(
&'life0 self,
key_hash: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<ApiKey>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn find_by_user<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<ApiKey>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn revoke<'life0, 'async_trait>(
&'life0 self,
key_id: Uuid,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn touch_last_used<'life0, 'async_trait>(
&'life0 self,
key_id: Uuid,
at: DateTime<Utc>,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§impl AuditLogRepository for MemoryStore
impl AuditLogRepository for MemoryStore
fn append<'life0, 'async_trait>(
&'life0 self,
entry: CreateAuditLog,
) -> Pin<Box<dyn Future<Output = Result<AuditLog>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_user<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
limit: u32,
) -> Pin<Box<dyn Future<Output = Result<Vec<AuditLog>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_org<'life0, 'async_trait>(
&'life0 self,
org_id: Uuid,
limit: u32,
) -> Pin<Box<dyn Future<Output = Result<Vec<AuditLog>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§impl Clone for MemoryStore
impl Clone for MemoryStore
Source§fn clone(&self) -> MemoryStore
fn clone(&self) -> MemoryStore
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl CredentialRepository for MemoryStore
impl CredentialRepository for MemoryStore
fn create<'life0, 'async_trait>(
&'life0 self,
data: CreateCredential,
) -> Pin<Box<dyn Future<Output = Result<Credential>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_password_hash<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<String>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_user_and_kind<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
kind: CredentialKind,
) -> Pin<Box<dyn Future<Output = Result<Option<Credential>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete_by_user_and_kind<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
kind: CredentialKind,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§impl Default for MemoryStore
impl Default for MemoryStore
Source§fn default() -> MemoryStore
fn default() -> MemoryStore
Returns the “default value” for a type. Read more
Source§impl InviteRepository for MemoryStore
impl InviteRepository for MemoryStore
fn create<'life0, 'async_trait>(
&'life0 self,
data: CreateInvite,
) -> Pin<Box<dyn Future<Output = Result<Invite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_token_hash<'life0, 'life1, 'async_trait>(
&'life0 self,
hash: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Invite>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn accept<'life0, 'async_trait>(
&'life0 self,
invite_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Invite>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete_expired<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<u64>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§impl OAuthAccountRepository for MemoryStore
impl OAuthAccountRepository for MemoryStore
fn upsert<'life0, 'async_trait>(
&'life0 self,
data: UpsertOAuthAccount,
) -> Pin<Box<dyn Future<Output = Result<OAuthAccount>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_provider<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
provider: &'life1 str,
provider_user_id: &'life2 str,
) -> Pin<Box<dyn Future<Output = Result<Option<OAuthAccount>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn find_by_user<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<OAuthAccount>>> + 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,
Source§impl OrgRepository for MemoryStore
impl OrgRepository for MemoryStore
fn create<'life0, 'async_trait>(
&'life0 self,
data: CreateOrg,
) -> Pin<Box<dyn Future<Output = Result<Organization>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_id<'life0, 'async_trait>(
&'life0 self,
id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Organization>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_slug<'life0, 'life1, 'async_trait>(
&'life0 self,
slug: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Organization>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn add_member<'life0, 'async_trait>(
&'life0 self,
org_id: Uuid,
user_id: Uuid,
role_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Membership>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn remove_member<'life0, 'async_trait>(
&'life0 self,
org_id: Uuid,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_members<'life0, 'async_trait>(
&'life0 self,
org_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<Membership>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_roles<'life0, 'async_trait>(
&'life0 self,
org_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<Role>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create_role<'life0, 'async_trait>(
&'life0 self,
org_id: Uuid,
name: String,
permissions: Vec<String>,
) -> Pin<Box<dyn Future<Output = Result<Role>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn update_member_role<'life0, 'async_trait>(
&'life0 self,
org_id: Uuid,
user_id: Uuid,
role_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Membership>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§impl SessionRepository for MemoryStore
impl SessionRepository for MemoryStore
fn create<'life0, 'async_trait>(
&'life0 self,
data: CreateSession,
) -> Pin<Box<dyn Future<Output = Result<Session>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_token_hash<'life0, 'life1, 'async_trait>(
&'life0 self,
hash: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Session>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn find_by_user<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<Session>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn invalidate<'life0, 'async_trait>(
&'life0 self,
session_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn invalidate_all_for_user<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn set_org<'life0, 'async_trait>(
&'life0 self,
session_id: Uuid,
org_id: Option<Uuid>,
) -> Pin<Box<dyn Future<Output = Result<Session>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§impl UserRepository for MemoryStore
impl UserRepository for MemoryStore
fn find_by_id<'life0, 'async_trait>(
&'life0 self,
id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<User>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_by_email<'life0, 'life1, 'async_trait>(
&'life0 self,
email: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<User>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn find_by_username<'life0, 'life1, 'async_trait>(
&'life0 self,
username: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<User>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list<'life0, 'async_trait>(
&'life0 self,
offset: u32,
limit: u32,
) -> Pin<Box<dyn Future<Output = Result<Vec<User>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create<'life0, 'async_trait>(
&'life0 self,
data: CreateUser,
) -> Pin<Box<dyn Future<Output = Result<User>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn update<'life0, 'async_trait>(
&'life0 self,
id: Uuid,
data: UpdateUser,
) -> Pin<Box<dyn Future<Output = Result<User>> + 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,
Auto Trait Implementations§
impl Freeze for MemoryStore
impl RefUnwindSafe for MemoryStore
impl Send for MemoryStore
impl Sync for MemoryStore
impl Unpin for MemoryStore
impl UnsafeUnpin for MemoryStore
impl UnwindSafe for MemoryStore
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