ClaimsPrincipalPermission.Intersect(IPermission) Método
Definição
Retorna uma permissão que é a interseção da permissão atual e da permissão especificada.Returns a permission that is the intersection of the current permission and the specified permission.
public:
virtual System::Security::IPermission ^ Intersect(System::Security::IPermission ^ target);
public System.Security.IPermission Intersect (System.Security.IPermission target);
abstract member Intersect : System.Security.IPermission -> System.Security.IPermission
override this.Intersect : System.Security.IPermission -> System.Security.IPermission
Public Function Intersect (target As IPermission) As IPermission
Parâmetros
- target
- IPermission
A permissão a interseccionar com a permissão atual.The permission to intersect with the current permission. Ele deve ser uma instância de ClaimsPrincipalPermission.It must be an instance of ClaimsPrincipalPermission.
Retornos
Uma nova ClaimsPrincipalPermission que representa a interseção da permissão atual e da permissão especificada ou então null, se target é null ou não é uma instância de ClaimsPrincipalPermission.A new ClaimsPrincipalPermission that represents the intersection of the current permission and the specified permission; or null if target is null or is not an instance of ClaimsPrincipalPermission.
Implementações
Comentários
A permissão retornada tem apenas os pares Resource-Action que estavam presentes na permissão atual e na permissão especificada.The permission that is returned has only the resource-action pairs that were present both in the current permission and in the specified permission. Os pares de ação de recurso que existiam em apenas uma ou outra das permissões não são incluídos.Resource-action pairs that existed in only one or the other of the permissions are not included. Para Demand que um tenha sucesso na nova permissão, a entidade atual só precisa ser autorizada para os pares de recurso-ação que eram comuns à permissão atual e à permissão especificada.For a Demand to succeed on the new permission, the current principal only needs to be authorized for the resource-action pairs that were common to the current permission and the specified permission.