class Grant extends Fluent

register 되어진 권한의 실제 값들을 보관하는 클래스.

Constants

RATING_TYPE

GROUP_TYPE

USER_TYPE

EXCEPT_TYPE

VGROUP_TYPE

Methods

$this
set(string $action, string|array $type, mixed $value = null)

Set grant information

$this
add(string $action, string|array $type, mixed $value = null)

Add grant information

$this
except(string $action, mixed $userIds = null)

Add except user identifier

array
makeValue(string|array $type, mixed $value = null)

Make value array from arguments

array
valueFilter(array $value)

Value filter

bool
isAllowType(stirng $type)

Check type is allowed

Details

at line 51
$this set(string $action, string|array $type, mixed $value = null)

Set grant information

Parameters

string $action action type
string|array $type value type
mixed $value values

Return Value

$this

Exceptions

InvalidArgumentException

at line 68
$this add(string $action, string|array $type, mixed $value = null)

Add grant information

Parameters

string $action action type
string|array $type value type
mixed $value values

Return Value

$this

at line 88
$this except(string $action, mixed $userIds = null)

Add except user identifier

Parameters

string $action action type
mixed $userIds user id or ids

Return Value

$this

at line 102
protected array makeValue(string|array $type, mixed $value = null)

Make value array from arguments

Parameters

string|array $type value type
mixed $value values

Return Value

array

at line 129
protected array valueFilter(array $value)

Value filter

Parameters

array $value values

Return Value

array

at line 147
protected bool isAllowType(stirng $type)

Check type is allowed

Parameters

stirng $type type

Return Value

bool