WindowsIdentity.Groups プロパティとは何? わかりやすく解説 Weblio辞書 (original) (raw)

メモ : このプロパティは、.NET Framework version 2.0新しく追加されたものです。

現在の Windows ユーザー属しているグループ取得します

名前空間: System.Security.Principal
アセンブリ: mscorlib (mscorlib.dll 内)
構文構文

Visual Basic (宣言)

Public ReadOnly Property Groups As IdentityReferenceCollection

Visual Basic (使用法)

Dim instance As WindowsIdentity Dim value As IdentityReferenceCollection

value = instance.Groups

C#

public IdentityReferenceCollection Groups { get; }

C++

public: property IdentityReferenceCollection^ Groups { IdentityReferenceCollection^ get (); }

J#

/** @property */ public IdentityReferenceCollection get_Groups ()

JScript

public function get Groups () : IdentityReferenceCollection

プロパティ
現在の Windows ユーザー属しているグループを表す IdentityReferenceCollection オブジェクト

使用例使用例

Groups プロパティ使用して現在のユーザー属しているグループID 参照表示する方法次のコード例示します。このコード例は、WindowsIdentity クラストピック取り上げているコード例一部分です。

Visual Basic

Dim authenticationType = "WindowsAuthentication" Dim windowsIdentity As _ New WindowsIdentity(logonToken, authenticationType)

C#

string authenticationType = "WindowsAuthentication"; WindowsIdentity windowsIdentity = new WindowsIdentity(logonToken, authenticationType);

C++

String^ authenticationType = "WindowsAuthentication"; WindowsIdentity^ windowsIdentity = gcnew WindowsIdentity( logonToken,authenticationType );

J#

String authenticationType = "WindowsAuthentication"; WindowsIdentity windowsIdentity = new WindowsIdentity(logonToken, authenticationType);

プラットフォームプラットフォーム

Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

開発プラットフォーム中には.NET Framework によってサポートされていないバージョンありますサポートされているバージョンについては、「システム要件」を参照してください

バージョン情報バージョン情報

.NET Framework
サポート対象 : 2.0

参照参照

関連項目
WindowsIdentity クラス
WindowsIdentity メンバ
System.Security.Principal 名前空間