pub trait TenantService: Send + Sync + 'static {
fn create<'life0, 'async_trait>(
&'life0 self,
request: Request<CreateTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<CreateTenantResponse>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn get<'life0, 'async_trait>(
&'life0 self,
request: Request<GetTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<GetTenantResponse>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn update<'life0, 'async_trait>(
&'life0 self,
request: Request<UpdateTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn delete<'life0, 'async_trait>(
&'life0 self,
request: Request<DeleteTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn list<'life0, 'async_trait>(
&'life0 self,
request: Request<ListTenantsRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<ListTenantsResponse>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn add_user<'life0, 'async_trait>(
&'life0 self,
request: Request<AddTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn get_user<'life0, 'async_trait>(
&'life0 self,
request: Request<GetTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<GetTenantUserResponse>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn update_user<'life0, 'async_trait>(
&'life0 self,
request: Request<UpdateTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn delete_user<'life0, 'async_trait>(
&'life0 self,
request: Request<DeleteTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
fn list_users<'life0, 'async_trait>(
&'life0 self,
request: Request<ListTenantUsersRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<ListTenantUsersResponse>, Status>> + Send + 'async_trait>>
where
Self: 'async_trait,
'life0: 'async_trait;
}
Expand description
Generated trait containing gRPC methods that should be implemented for use with TenantServiceServer.
Required Methods§
sourcefn create<'life0, 'async_trait>(
&'life0 self,
request: Request<CreateTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<CreateTenantResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create<'life0, 'async_trait>(
&'life0 self,
request: Request<CreateTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<CreateTenantResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create a new tenant.
sourcefn get<'life0, 'async_trait>(
&'life0 self,
request: Request<GetTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<GetTenantResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get<'life0, 'async_trait>(
&'life0 self,
request: Request<GetTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<GetTenantResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get the tenant for the given ID.
sourcefn update<'life0, 'async_trait>(
&'life0 self,
request: Request<UpdateTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn update<'life0, 'async_trait>(
&'life0 self,
request: Request<UpdateTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Update the given tenant.
sourcefn delete<'life0, 'async_trait>(
&'life0 self,
request: Request<DeleteTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete<'life0, 'async_trait>(
&'life0 self,
request: Request<DeleteTenantRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Delete the tenant with the given ID.
sourcefn list<'life0, 'async_trait>(
&'life0 self,
request: Request<ListTenantsRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<ListTenantsResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list<'life0, 'async_trait>(
&'life0 self,
request: Request<ListTenantsRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<ListTenantsResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get the list of tenants.
sourcefn add_user<'life0, 'async_trait>(
&'life0 self,
request: Request<AddTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn add_user<'life0, 'async_trait>(
&'life0 self,
request: Request<AddTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Add an user to the tenant. Note: the user must already exist.
sourcefn get_user<'life0, 'async_trait>(
&'life0 self,
request: Request<GetTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<GetTenantUserResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_user<'life0, 'async_trait>(
&'life0 self,
request: Request<GetTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<GetTenantUserResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get the the tenant user for the given tenant and user IDs.
sourcefn update_user<'life0, 'async_trait>(
&'life0 self,
request: Request<UpdateTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn update_user<'life0, 'async_trait>(
&'life0 self,
request: Request<UpdateTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Update the given tenant user.
sourcefn delete_user<'life0, 'async_trait>(
&'life0 self,
request: Request<DeleteTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete_user<'life0, 'async_trait>(
&'life0 self,
request: Request<DeleteTenantUserRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<()>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Delete the given tenant user.
sourcefn list_users<'life0, 'async_trait>(
&'life0 self,
request: Request<ListTenantUsersRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<ListTenantUsersResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_users<'life0, 'async_trait>(
&'life0 self,
request: Request<ListTenantUsersRequest>
) -> Pin<Box<dyn Future<Output = Result<Response<ListTenantUsersResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get the list of tenant users.