Passed
Push — develop ( ded98c...5fca67 )
by Mathieu
02:55
created

Access::getRole()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 10
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 6
c 0
b 0
f 0
dl 0
loc 10
rs 10
cc 2
nc 2
nop 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace KunicMarko\SonataAnnotationBundle\Annotation;
6
7
/**
8
 * Access control annotation.
9
 *
10
 * Allow you to control permission per role.
11
 *
12
 * @Annotation
13
 * @Target("CLASS")
14
 *
15
 * @author Marko Kunic <[email protected]>
16
 * @author Mathieu Wambre <[email protected]>
17
 */
18
final class Access implements AnnotationInterface
19
{
20
    /**
21
     * Allowed role.
22
     *
23
     * @var string
24
     */
25
    public string $role;
26
27
    /**
28
     * Allowed permissions.
29
     *
30
     * @var array
31
     */
32
    public array $permissions = [];
33
}
34