WindowsAccountType 열거형
정의
사용되는 Windows 계정의 형식을 지정합니다.Specifies the type of Windows account used.
public enum class WindowsAccountType
[System.Runtime.InteropServices.ComVisible(true)]
public enum WindowsAccountType
public enum WindowsAccountType
[System.Serializable]
public enum WindowsAccountType
[System.Runtime.InteropServices.ComVisible(true)]
[System.Serializable]
public enum WindowsAccountType
[<System.Runtime.InteropServices.ComVisible(true)>]
type WindowsAccountType =
type WindowsAccountType =
[<System.Serializable>]
type WindowsAccountType =
[<System.Runtime.InteropServices.ComVisible(true)>]
[<System.Serializable>]
type WindowsAccountType =
Public Enum WindowsAccountType
- 상속
- 특성
필드
Anonymous | 3 | 익명 계정입니다.An anonymous account. |
Guest | 1 | Windows 게스트 계정입니다.A Windows guest account. |
Normal | 0 | 표준 사용자 계정입니다.A standard user account. |
System | 2 | Windows 시스템 계정입니다.A Windows system account. |
예제
다음 예제에서는 생성자를 사용 하 여 WindowsIdentity WindowsIdentity 지정 된 windows 계정 토큰, 지정 된 인증 형식 및 지정 된 windows 계정 형식이 나타내는 사용자에 대해 클래스의 새 인스턴스를 만드는 방법을 보여 줍니다.The following example shows how to use the WindowsIdentity constructor to create a new instance of the WindowsIdentity class for the user represented by the specified Windows account token, the specified authentication type, and the specified Windows account type. 이 코드 예제는에 대해 제공 된 큰 예제의 일부는 WindowsIdentity 클래스입니다.This code example is part of a larger example provided for the WindowsIdentity class.
void IntPtrStringTypeConstructor( IntPtr logonToken )
{
// Construct a WindowsIdentity object using the input account token,
// and the specified authentication type and Windows account type.
String^ authenticationType = "WindowsAuthentication";
WindowsAccountType guestAccount = WindowsAccountType::Guest;
WindowsIdentity^ windowsIdentity = gcnew WindowsIdentity( logonToken,authenticationType,guestAccount );
Console::WriteLine( "Created a Windows identity object named {0}.", windowsIdentity->Name );
}
private static void IntPtrStringTypeConstructor(IntPtr logonToken)
{
// Construct a WindowsIdentity object using the input account token,
// and the specified authentication type, and Windows account type.
string authenticationType = "WindowsAuthentication";
WindowsAccountType guestAccount = WindowsAccountType.Guest;
WindowsIdentity windowsIdentity =
new WindowsIdentity(logonToken, authenticationType, guestAccount);
Console.WriteLine("Created a Windows identity object named " +
windowsIdentity.Name + ".");
}
Private Sub IntPtrStringTypeConstructor(ByVal logonToken As IntPtr)
' Construct a WindowsIdentity object using the input account token,
' and the specified authentication type and Windows account type.
Dim authenticationType As String = "WindowsAuthentication"
Dim guestAccount As WindowsAccountType = WindowsAccountType.Guest
Dim windowsIdentity As _
New WindowsIdentity(logonToken, authenticationType, guestAccount)
WriteLine("Created a Windows identity object named " + _
windowsIdentity.Name + ".")
End Sub
설명
WindowsAccountType 열거형은 WindowsIdentity 클래스에서 사용됩니다.The WindowsAccountType enumeration is used by the WindowsIdentity class.