ISecurity.GetRoleAccessToResource

Returns the access level the passed-in role has for the specified resource.

public AccessRights GetRoleAccessToResource(string resourceID,
	Guid roleID,
	AccessRights defaultAccess);

Return Value

The access level for the role for the specified resource.

Parameters

resourceID
The identifier (Guid or Name) of the resource to check.
roleID
The ID of the role to check.
defaultAccess
The default access level to use if no access was found.

Remarks

GetRoleAccessToResource returns AccessRights.Full if the specified role is the Administrator role. If there's no record for the specified role in the Permissions table, the specified default access is used.

See also:

Interface ISecurity