IdentityServiceCollectionExtensions.AddIdentityCore 方法

定义

重载

AddIdentityCore<TUser>(IServiceCollection)

为指定的用户类型添加和配置标识系统。 默认情况下不会添加角色服务,但可以使用 添加 AddRoles<TRole>()角色服务。

AddIdentityCore<TUser>(IServiceCollection, Action<IdentityOptions>)

为指定的用户类型添加和配置标识系统。 默认情况下不会添加角色服务,但可以使用 添加 AddRoles<TRole>()角色服务。

AddIdentityCore<TUser>(IServiceCollection)

Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs

为指定的用户类型添加和配置标识系统。 默认情况下不会添加角色服务,但可以使用 添加 AddRoles<TRole>()角色服务。

public static Microsoft.AspNetCore.Identity.IdentityBuilder AddIdentityCore<TUser> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services) where TUser : class;
static member AddIdentityCore : Microsoft.Extensions.DependencyInjection.IServiceCollection -> Microsoft.AspNetCore.Identity.IdentityBuilder (requires 'User : null)
<Extension()>
Public Function AddIdentityCore(Of TUser As Class) (services As IServiceCollection) As IdentityBuilder

类型参数

TUser

表示系统中用户的类型。

参数

services
IServiceCollection

应用程序中可用的服务。

适用于

AddIdentityCore<TUser>(IServiceCollection, Action<IdentityOptions>)

Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs
Source:
IdentityServiceCollectionExtensions.cs

为指定的用户类型添加和配置标识系统。 默认情况下不会添加角色服务,但可以使用 添加 AddRoles<TRole>()角色服务。

public static Microsoft.AspNetCore.Identity.IdentityBuilder AddIdentityCore<TUser> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.AspNetCore.Identity.IdentityOptions> setupAction) where TUser : class;
static member AddIdentityCore : Microsoft.Extensions.DependencyInjection.IServiceCollection * Action<Microsoft.AspNetCore.Identity.IdentityOptions> -> Microsoft.AspNetCore.Identity.IdentityBuilder (requires 'User : null)
<Extension()>
Public Function AddIdentityCore(Of TUser As Class) (services As IServiceCollection, setupAction As Action(Of IdentityOptions)) As IdentityBuilder

类型参数

TUser

表示系统中用户的类型。

参数

services
IServiceCollection

应用程序中可用的服务。

setupAction
Action<IdentityOptions>

用于配置 的操作 IdentityOptions

适用于