Connectivity Software User's Guide and Reference
IntersectWith Method (UAPermissionAssignment)



OpcLabs.EasyOpcUAPrimitives Assembly > OpcLabs.EasyOpc.UA.Security.Subject Namespace > UAPermissionAssignment Class : IntersectWith Method
The other permission assignment to intersect with.

The value of this parameter cannot be null (Nothing in Visual Basic).

Specifies whether roles with no permissions remaining after the intersection should be removed from the current assignment. If true, such roles are removed; otherwise, they are retained.
Intersects this permission assignment with another, keeping only the roles that are common between the two assignments. For each common role, the permissions are combined using a bitwise AND operation, ensuring that only permissions present in both assignments are retained. This operation modifies the current permission assignment in place.
Syntax
'Declaration
 
Public Sub IntersectWith( _
   ByVal other As UAPermissionAssignment, _
   Optional ByVal removeEmptyPermissions As Boolean _
) 
'Usage
 
Dim instance As UAPermissionAssignment
Dim other As UAPermissionAssignment
Dim removeEmptyPermissions As Boolean
 
instance.IntersectWith(other, removeEmptyPermissions)
public:
void IntersectWith( 
   UAPermissionAssignment^ other,
   bool removeEmptyPermissions
) 

Parameters

other
The other permission assignment to intersect with.

The value of this parameter cannot be null (Nothing in Visual Basic).

removeEmptyPermissions
Specifies whether roles with no permissions remaining after the intersection should be removed from the current assignment. If true, such roles are removed; otherwise, they are retained.
Exceptions
ExceptionDescription

A null reference (Nothing in Visual Basic) is passed to a method that does not accept it as a valid argument.

This is a usage error, i.e. it will never occur (the exception will not be thrown) in a correctly written program. Your code should not catch this exception.

Requirements

Target Platforms: .NET Framework: Windows 10 (selected versions), Windows 11 (selected versions), Windows Server 2016, Windows Server 2022; .NET: Linux, macOS, Microsoft Windows

See Also