SecurityRoleAttribute Constructor (String)

 

Initializes a new instance of the SecurityRoleAttribute class and sets the Role property.

Namespace:   System.EnterpriseServices
Assembly:  System.EnterpriseServices (in System.EnterpriseServices.dll)

public SecurityRoleAttribute(
	string role
)

Parameters

role
Type: System.String

A security role for the application, component, interface, or method.

The following code example demonstrates the use of this attribute to associate a role with an assembly that contains ServicedComponent classes.

// Create a security role for the component.
[assembly: SecurityRole("Manager")]

.NET Framework
Available since 1.1
Return to top
Show: