RoleStore<TRole,TContext,TKey> 类
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
为角色创建持久性存储的新实例。
generic <typename TRole, typename TContext, typename TKey>
where TRole : IdentityRole<TKey> where TContext : DbContext where TKey : IEquatable<TKey>public ref class RoleStore : Microsoft::AspNetCore::Identity::EntityFrameworkCore::RoleStore<TRole, TContext, TKey, Microsoft::AspNetCore::Identity::EntityFrameworkCore::IdentityUserRole<TKey> ^, Microsoft::AspNetCore::Identity::EntityFrameworkCore::IdentityRoleClaim<TKey> ^>, IDisposable, Microsoft::AspNetCore::Identity::IQueryableRoleStore<TRole>, Microsoft::AspNetCore::Identity::IRoleClaimStore<TRole>, Microsoft::AspNetCore::Identity::IRoleStore<TRole>
generic <typename TRole, typename TContext, typename TKey>
where TRole : IdentityRole<TKey> where TContext : DbContext where TKey : IEquatable<TKey>public ref class RoleStore : Microsoft::AspNetCore::Identity::EntityFrameworkCore::RoleStore<TRole, TContext, TKey, Microsoft::AspNetCore::Identity::IdentityUserRole<TKey> ^, Microsoft::AspNetCore::Identity::IdentityRoleClaim<TKey> ^>, IDisposable, Microsoft::AspNetCore::Identity::IQueryableRoleStore<TRole>, Microsoft::AspNetCore::Identity::IRoleClaimStore<TRole>, Microsoft::AspNetCore::Identity::IRoleStore<TRole>
public class RoleStore<TRole,TContext,TKey> : Microsoft.AspNetCore.Identity.EntityFrameworkCore.RoleStore<TRole,TContext,TKey,Microsoft.AspNetCore.Identity.EntityFrameworkCore.IdentityUserRole<TKey>,Microsoft.AspNetCore.Identity.EntityFrameworkCore.IdentityRoleClaim<TKey>>, IDisposable, Microsoft.AspNetCore.Identity.IQueryableRoleStore<TRole>, Microsoft.AspNetCore.Identity.IRoleClaimStore<TRole>, Microsoft.AspNetCore.Identity.IRoleStore<TRole> where TRole : IdentityRole<TKey> where TContext : DbContext where TKey : IEquatable<TKey>
public class RoleStore<TRole,TContext,TKey> : Microsoft.AspNetCore.Identity.EntityFrameworkCore.RoleStore<TRole,TContext,TKey,Microsoft.AspNetCore.Identity.IdentityUserRole<TKey>,Microsoft.AspNetCore.Identity.IdentityRoleClaim<TKey>>, IDisposable, Microsoft.AspNetCore.Identity.IQueryableRoleStore<TRole>, Microsoft.AspNetCore.Identity.IRoleClaimStore<TRole>, Microsoft.AspNetCore.Identity.IRoleStore<TRole> where TRole : IdentityRole<TKey> where TContext : DbContext where TKey : IEquatable<TKey>
type RoleStore<'Role, 'Context, 'Key (requires 'Role :> IdentityRole<'Key> and 'Context :> DbContext and 'Key :> IEquatable<'Key>)> = class
inherit RoleStore<'Role, 'Context, 'Key, IdentityUserRole<'Key>, IdentityRoleClaim<'Key> (requires 'Role :> IdentityRole<'Key> and 'Context :> DbContext and 'Key :> IEquatable<'Key>)>
interface IQueryableRoleStore<'Role (requires 'Role :> IdentityRole<'Key>)>
interface IRoleStore<'Role (requires 'Role :> IdentityRole<'Key>)>
interface IDisposable
interface IRoleClaimStore<'Role (requires 'Role :> IdentityRole<'Key>)>
Public Class RoleStore(Of TRole, TContext, TKey)
Inherits RoleStore(Of TRole, TContext, TKey, IdentityUserRole(Of TKey), IdentityRoleClaim(Of TKey))
Implements IDisposable, IQueryableRoleStore(Of TRole), IRoleClaimStore(Of TRole), IRoleStore(Of TRole)
类型参数
- TRole
表示角色的类的类型。
- TContext
用于访问存储的数据上下文类的类型。
- TKey
角色的主键的类型。
- 继承
-
RoleStore<TRole,TContext,TKey>
- 继承
-
RoleStore<TRole,TContext,TKey>
- 派生
- 实现
构造函数
RoleStore<TRole,TContext,TKey>(TContext, IdentityErrorDescriber) |
构造 RoleStore<TRole,TContext,TKey> 的新实例。 |
属性
AutoSaveChanges |
获取或设置一个标志,指示在调用 CreateAsync、UpdateAsync 和 DeleteAsync 后是否应保留更改。 (继承自 RoleStore<TRole,TContext,TKey,TUserRole,TRoleClaim>) |
Context |
获取此存储的数据库上下文。 (继承自 RoleStore<TRole,TContext,TKey,TUserRole,TRoleClaim>) |
ErrorDescriber |
获取或设置 IdentityErrorDescriber 当前操作发生的任何错误的 。 (继承自 RoleStore<TRole,TContext,TKey,TUserRole,TRoleClaim>) |
Roles |
存储区包含的角色的导航属性。 (继承自 RoleStore<TRole,TContext,TKey,TUserRole,TRoleClaim>) |