PublisherIdentityPermission.IsSubsetOf(IPermission) 方法
定义
确定当前权限是否为指定权限的子集。Determines whether the current permission is a subset of the specified permission.
public:
override bool IsSubsetOf(System::Security::IPermission ^ target);
public override bool IsSubsetOf (System.Security.IPermission target);
override this.IsSubsetOf : System.Security.IPermission -> bool
Public Overrides Function IsSubsetOf (target As IPermission) As Boolean
参数
- target
- IPermission
将要测试子集关系的权限。A permission that is to be tested for the subset relationship. 此权限必须与当前权限属于同一类型。This permission must be of the same type as the current permission.
返回
如果当前权限是指定权限的子集,则为 true;否则为 false。true if the current permission is a subset of the specified permission; otherwise, false.
例外
target 参数不为 null,并且与当前权限不属于同一类型。The target parameter is not null and is not of the same type as the current permission.
注解
如果两个权限相等,则当前权限是指定权限的子集。The current permission is a subset of the specified permission if the two permissions are equal. 如果此方法返回 true ,则当前权限表示对受保护资源的相同访问权限。If this method returns true, the current permission represents the same access to the protected resource as the specified permission.
PublisherIdentityPermissionIsSubsetOf Intersect Union 仅当当前权限等于指定权限时,才支持 (、和) 设置操作。PublisherIdentityPermission supports set operations (IsSubsetOf, Intersect, and Union) only when the current permission is equal to the specified permission.