Class UserServiceRepositoryBase<TUserEntity>
public abstract class UserServiceRepositoryBase<TUserEntity> : UserServiceBase, IUserService where TUserEntity : EntityBase, IUser
Type Parameters
TUserEntity
- Inheritance
-
UserServiceRepositoryBase<TUserEntity>
- Implements
- Inherited Members
Constructors
UserServiceRepositoryBase(AuthenticationStateProvider, IUserRepository<TUserEntity>)
protected UserServiceRepositoryBase(AuthenticationStateProvider authenticationStateProvider, IUserRepository<TUserEntity> userRepository)
Parameters
authenticationStateProviderAuthenticationStateProvideruserRepositoryIUserRepository<TUserEntity>
Methods
CreateUserEntityAsync(ClaimsPrincipal, string)
protected abstract Task<TUserEntity> CreateUserEntityAsync(ClaimsPrincipal claimsPrincipal, string identity)
Parameters
claimsPrincipalClaimsPrincipalidentitystring
Returns
- Task<TUserEntity>
GetAllAsync()
protected override IAsyncEnumerable<IUser> GetAllAsync()
Returns
GetUserAsync(ClaimsPrincipal)
protected override Task<IUser> GetUserAsync(ClaimsPrincipal claimsPrincipal)
Parameters
claimsPrincipalClaimsPrincipal
Returns
SeedUserNameAsync(string, string)
Sets the user's display name only if it is currently null/empty. Used by the invitation-accept flow to promote the admin-entered invitation name into the new user's identity without clobbering an IdP-provided name.
public override Task SeedUserNameAsync(string userKey, string name)
Parameters
Returns
SetUserNameAsync(string, string)
Always sets the user's display name. Used by the user self-edit flow where the caller has explicitly chosen a name for themselves.
public override Task SetUserNameAsync(string userKey, string name)