PermissionData::getType()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 1
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * This file is part of the zibios/sharep.
7
 *
8
 * (c) Zbigniew Ślązak
9
 */
10
11
namespace App\Voter\Configuration;
12
13
class PermissionData
14
{
15
    /** @var string */
16
    private $type;
17
    /** @var string */
18
    private $class;
19
    /** @var bool */
20
    private $isNullable;
21
22 16
    public function __construct(string $roleValue, string $class, bool $isNullable)
23
    {
24 16
        $this->type = $roleValue;
25 16
        $this->class = $class;
26 16
        $this->isNullable = $isNullable;
27 16
    }
28
29 16
    public function getType(): string
30
    {
31 16
        return $this->type;
32
    }
33
34 15
    public function getClass(): string
35
    {
36 15
        return $this->class;
37
    }
38
39 4
    public function isNullable(): bool
40
    {
41 4
        return $this->isNullable;
42
    }
43
}
44