System.Security.PermissionSet.Intersect Method

Creates and returns a permission set that is the intersection of the current System.Security.PermissionSet and the specified System.Security.PermissionSet.

Syntax

public PermissionSet Intersect (PermissionSet other)

Parameters

other
A permission set to intersect with the current System.Security.PermissionSet.

Returns

A new permission set that represents the intersection of the current System.Security.PermissionSet and the specified target. This object is null if the intersection is empty.

Remarks

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.

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 System.Security.PermissionSet. Permission types that exist in only one of the two sets are excluded from the resulting set.

Requirements

Namespace: System.Security
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0