<< Click to Display Table of Contents >> NShape Reference
|
Decides whether the required permission is granted.
NShape 1.0.x
Syntax
bool IsGranted(Permission permission); bool IsGranted(Permission permission, char domainName); bool IsGranted(Permission permission, Shape shape); bool IsGranted(Permission permission, IEnumerable<Shape> shapes); |
Returns true, if the indicated permission is granted given the permission set.
If a domainName is given, the permission is checked for the specified domainName only.
If shapes are given, the permission is checked for the Shape.SecurityDomainName of each shape. If the indicated permission is not granted for at least one shape, false is returned. Returns false if the shape collection does not contain any shapes.
NShape 2.0
Syntax
bool IsGranted(Permission permission); bool IsGranted(Permission permission, SecurityAccess access); bool IsGranted(Permission permission, char domainName); bool IsGranted(Permission permission, SecurityAccess access, char domainName); bool IsGranted(Permission permission, ISecurityDomainObject securityDomainObject); bool IsGranted(Permission permission, SecurityAccess access, bool IsGranted<T>(Permission permission, IEnumerable<T> securityDomainObjects) bool IsGranted<T>(Permission permission, SecurityAccess access, |
Returns true, if the indicated permission is granted given the permission set.
If SecurityAccess is not specified, the check will be performed against SecurityAccess.Modify.
Please note that domain dependent permissions may only be checked against a domain name and security independent permissions may not be checked against domain names.