Edit

Share via


DnsPermission.Intersect(IPermission) Method

Definition

Creates a permission instance that is the intersection of the current permission instance and the specified permission instance.

public:
 override System::Security::IPermission ^ Intersect(System::Security::IPermission ^ target);
public override System.Security.IPermission Intersect(System.Security.IPermission target);
override this.Intersect : System.Security.IPermission -> System.Security.IPermission
Public Overrides Function Intersect (target As IPermission) As IPermission

Parameters

target
IPermission

The DnsPermission instance to intersect with the current instance.

Returns

A DnsPermission instance that represents the intersection of the current DnsPermission instance with the specified DnsPermission instance, or null if the intersection is empty. If both the current instance and target are unrestricted, this method returns a new DnsPermission instance that is unrestricted; otherwise, it returns null.

Exceptions

target is neither a DnsPermission nor null.

Remarks

The Intersect method returns a DnsPermission instance that allows the access defined by both the current DnsPermission instance and the specified DnsPermission instance. Any demand must pass both permissions to pass their intersection.

Applies to