| 1234567891011121314151617181920212223 |
- using System.Threading.Tasks;
- namespace Abp.Authorization
- {
- /// <summary>
- /// This class is used to permissions for users.
- /// </summary>
- public interface IPermissionChecker
- {
- /// <summary>
- /// Checks if current user is granted for a permission.
- /// </summary>
- /// <param name="permissionName">Name of the permission</param>
- Task<bool> IsGrantedAsync(string permissionName);
- /// <summary>
- /// Checks if a user is granted for a permission.
- /// </summary>
- /// <param name="user">User to check</param>
- /// <param name="permissionName">Name of the permission</param>
- Task<bool> IsGrantedAsync(UserIdentifier user, string permissionName);
- }
- }
|