Policy
abstract class Policy
Abstract class Policy
Properties
protected PermissionHandler | $perm | PermissionHandler instance | |
protected VirtualGroupRepositoryInterface | $vgroups | VirtualGroupRepository instance |
Methods
Permission|null
get(string $name, string $siteKey = 'default')
Get a permission
bool
array
extractExcepts(array $grants)
Extract except user information
bool
bool
bool
bool
bool
bool
string
bool
Details
at line 53
__construct(PermissionHandler $perm, VirtualGroupRepositoryInterface $vgroups)
Policy constructor.
at line 66
protected Permission|null
get(string $name, string $siteKey = 'default')
Get a permission
at line 79
protected bool
check(UserInterface $user, Permission $permission, string $action)
Check allows
at line 108
protected array
extractExcepts(array $grants)
Extract except user information
at line 126
protected bool
isExcepted(UserInterface $user, array $userIds = array())
Check except user
at line 143
protected bool
checker(UserInterface $user, string $type, mixed $value)
타입에 맞는 권한 판별 메서드를 호출 함.
at line 157
protected bool
groupInspect(UserInterface $user, array $criterion)
User 가 속한 그룹이 권한이 있는지 판별.
at line 176
protected bool
vgroupInspect(UserInterface $user, array $criterion)
User 가 속한 가상그룹이 권한이 있는지 판별.
at line 199
protected bool
userInspect(UserInterface $user, array $criterion)
User 가 권한이 있는 대상으로 지정되어 있는지 판별
at line 215
protected bool
ratingInspect(UserInterface $user, string $criterion)
User 가 권한이 있는 등급인지 판별
at line 230
protected string
userRating(UserInterface $user)
Get a User's rating keyword
at line 245
protected bool
isGuest(UserInterface $user)
전달된 사용자가 guest 인지 확인