pub struct FederationService { /* private fields */ }Implementations§
Source§impl FederationService
impl FederationService
pub fn new<P: PluginManagerApi>( config: &Config, plugin_manager: &P, ) -> Result<Self, FederationProviderError>
Trait Implementations§
Source§impl FederationApi for FederationService
impl FederationApi for FederationService
Source§fn cleanup<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
) -> Pin<Box<dyn Future<Output = Result<(), FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn cleanup<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
) -> Pin<Box<dyn Future<Output = Result<(), FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Cleanup expired resources.
Source§fn create_auth_state<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
auth_state: AuthState,
) -> Pin<Box<dyn Future<Output = Result<AuthState, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn create_auth_state<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
auth_state: AuthState,
) -> Pin<Box<dyn Future<Output = Result<AuthState, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Create new auth state.
Source§fn create_identity_provider<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
idp: IdentityProviderCreate,
) -> Pin<Box<dyn Future<Output = Result<IdentityProvider, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn create_identity_provider<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
idp: IdentityProviderCreate,
) -> Pin<Box<dyn Future<Output = Result<IdentityProvider, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Create Identity provider.
Source§fn create_mapping<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
mapping: Mapping,
) -> Pin<Box<dyn Future<Output = Result<Mapping, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn create_mapping<'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
mapping: Mapping,
) -> Pin<Box<dyn Future<Output = Result<Mapping, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Create mapping.
Source§fn delete_auth_state<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<(), FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_auth_state<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<(), FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete auth state.
Source§fn delete_identity_provider<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<(), FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_identity_provider<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<(), FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete identity provider.
Source§fn delete_mapping<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<(), FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_mapping<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<(), FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete identity provider.
Source§fn get_auth_state<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<Option<AuthState>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_auth_state<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<Option<AuthState>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get auth state by ID.
Source§fn get_identity_provider<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<Option<IdentityProvider>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_identity_provider<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<Option<IdentityProvider>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get single IDP by ID.
Source§fn get_mapping<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<Option<Mapping>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_mapping<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
) -> Pin<Box<dyn Future<Output = Result<Option<Mapping>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get single mapping by ID.
Source§fn list_identity_providers<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
params: &'life2 IdentityProviderListParameters,
) -> Pin<Box<dyn Future<Output = Result<Vec<IdentityProvider>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_identity_providers<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
params: &'life2 IdentityProviderListParameters,
) -> Pin<Box<dyn Future<Output = Result<Vec<IdentityProvider>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
List IDP.
Source§fn list_mappings<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
params: &'life2 MappingListParameters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Mapping>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn list_mappings<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
params: &'life2 MappingListParameters,
) -> Pin<Box<dyn Future<Output = Result<Vec<Mapping>, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
List mappings.
Source§fn update_identity_provider<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
idp: IdentityProviderUpdate,
) -> Pin<Box<dyn Future<Output = Result<IdentityProvider, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn update_identity_provider<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
idp: IdentityProviderUpdate,
) -> Pin<Box<dyn Future<Output = Result<IdentityProvider, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Update Identity provider.
Source§fn update_mapping<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
mapping: MappingUpdate,
) -> Pin<Box<dyn Future<Output = Result<Mapping, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn update_mapping<'a, 'life0, 'life1, 'async_trait>(
&'life0 self,
state: &'life1 ServiceState,
id: &'a str,
mapping: MappingUpdate,
) -> Pin<Box<dyn Future<Output = Result<Mapping, FederationProviderError>> + Send + 'async_trait>>where
Self: 'async_trait,
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Update mapping
Auto Trait Implementations§
impl Freeze for FederationService
impl !RefUnwindSafe for FederationService
impl Send for FederationService
impl Sync for FederationService
impl Unpin for FederationService
impl UnsafeUnpin for FederationService
impl !UnwindSafe for FederationService
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> 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 more