PermissionSet.Intersect(PermissionSet) メソッド

定義

現在の PermissionSet と指定した PermissionSet の積集合であるアクセス許可セットを作成して返します。Creates and returns a permission set that is the intersection of the current PermissionSet and the specified PermissionSet.

public:
 System::Security::PermissionSet ^ Intersect(System::Security::PermissionSet ^ other);
public:
 virtual System::Security::PermissionSet ^ Intersect(System::Security::PermissionSet ^ other);
public System.Security.PermissionSet Intersect (System.Security.PermissionSet other);
public virtual System.Security.PermissionSet Intersect (System.Security.PermissionSet other);
member this.Intersect : System.Security.PermissionSet -> System.Security.PermissionSet
abstract member Intersect : System.Security.PermissionSet -> System.Security.PermissionSet
override this.Intersect : System.Security.PermissionSet -> System.Security.PermissionSet
Public Function Intersect (other As PermissionSet) As PermissionSet
Public Overridable Function Intersect (other As PermissionSet) As PermissionSet

パラメーター

other
PermissionSet

現在の PermissionSet と交差するアクセス許可セット。A permission set to intersect with the current PermissionSet.

戻り値

現在の PermissionSet と指定されたターゲットの積集合を表す新しいアクセス許可セット。A new permission set that represents the intersection of the current PermissionSet and the specified target. 積集合が空の場合、このオブジェクトは null です。This object is null if the intersection is empty.

次のコード例は、Intersect メソッドの使用方法を示しています。The following code example shows the use of the Intersect method. このコード例は、PermissionSet クラス用に用意されている大規模な例の一部です。This code example is part of a larger example provided for the PermissionSet class.

// Display the intersection of two permission sets.
PermissionSet^ ps3 = ps2->Intersect( ps1 );
Console::WriteLine( "The intersection of the first permission set and the second permission set = {0}", ps3 );
// Display the intersection of two permission sets.
PermissionSet ps3 = ps2.Intersect(ps1);
Console.WriteLine("The intersection of the first permission set and "
    + "the second permission set = " + ps3.ToString());
' Display the intersection of two permission sets.
Dim ps3 As PermissionSet = ps2.Intersect(ps1)
Console.WriteLine("The intersection of the first permission set and " & "the second permission set = " & ps3.ToString())

注釈

2つのアクセス許可セットの積集合は、両方が共通で記述する一連の操作を記述するアクセス許可セットです。The intersection of two permission sets is a permission set that describes the set of operations they both describe in common. 具体的には、両方のアクセス許可セットを渡すすべての要求が交差部分も渡すように、最小アクセス許可を表します。Specifically, it represents the minimum permissions such that any demand that passes both permission sets also passes their intersection.

両方のセットに存在するアクセス許可の種類ごとに、これらのアクセス許可の2つのインスタンスが、アクセス許可の Intersect メソッドを使用して交差します。結果として得られるアクセス許可は、結果の PermissionSetに含まれます。For each type of permission that is present in both sets, the two instances of those permissions are intersected using the permission's Intersect method; the resulting permission is included in the resulting PermissionSet. 2つのセットのうち1つだけに存在するアクセス許可の種類は、結果セットから除外されます。Permission types that exist in only one of the two sets are excluded from the resulting set.

適用対象