Initializes an instance of T:Microsoft.IdentityModel.Claims.ClaimsIdentity with an empty T:Microsoft.IdentityModel.Claims.Claim collection, the specified authentication type, name claim type, and role claim type.
Пространство имен: Microsoft.IdentityModel.Claims
Сборка: Microsoft.IdentityModel (в microsoft.identitymodel.dll)
Использование
Visual Basic |
---|
Dim authenticationType As String Dim nameClaimType As String Dim roleClaimType As String Dim instance As New ClaimsIdentity(authenticationType, nameClaimType, roleClaimType) |
Синтаксис
Visual Basic |
---|
Public Sub New ( _ authenticationType As String, _ nameClaimType As String, _ roleClaimType As String _ ) |
C# |
---|
public ClaimsIdentity ( string authenticationType, string nameClaimType, string roleClaimType ) |
C++ |
---|
public: ClaimsIdentity ( String^ authenticationType, String^ nameClaimType, String^ roleClaimType ) |
J# |
---|
public ClaimsIdentity ( String authenticationType, String nameClaimType, String roleClaimType ) |
JScript |
---|
public function ClaimsIdentity ( authenticationType : String, nameClaimType : String, roleClaimType : String ) |
Параметры
- authenticationType
-
The type of authentication used.
- nameClaimType
-
The claim type to use for P:Microsoft.IdentityModel.Claims.ClaimsIdentity.Name.
- roleClaimType
-
The claim type to use for IClaimsPrincipal.IsInRole(string).
Исключения
Тип исключений | Условие |
---|
Примечания