Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
|||
Role | n/a |
0 / 0 |
n/a |
0 / 0 |
1 | n/a |
0 / 0 |
|||
__construct | n/a |
0 / 0 |
n/a |
0 / 0 |
1 |
1 | <?php |
2 | namespace WikibaseQuality\ConstraintReport; |
3 | |
4 | use LogicException; |
5 | |
6 | /** |
7 | * Enum of possible roles of a value for a {@link ViolationMessage} parameter. |
8 | * |
9 | * @author Lucas Werkmeister |
10 | * @license GPL-2.0-or-later |
11 | */ |
12 | class Role { |
13 | |
14 | /** |
15 | * Indicates that a formatted value acts as the subject of a statement. |
16 | * |
17 | * @var string |
18 | */ |
19 | public const SUBJECT = 'subject'; |
20 | |
21 | /** |
22 | * Indicates that a formatted value acts as the predicate of a statement. |
23 | * |
24 | * @var string |
25 | */ |
26 | public const PREDICATE = 'predicate'; |
27 | |
28 | /** |
29 | * Indicates that a formatted value acts as the object of a statement. |
30 | * |
31 | * @var string |
32 | */ |
33 | public const OBJECT = 'object'; |
34 | |
35 | /** |
36 | * Indicates that a formatted value is the property that introduced a constraint. |
37 | * |
38 | * @var string |
39 | */ |
40 | public const CONSTRAINT_PROPERTY = 'constraint-property'; |
41 | |
42 | /** |
43 | * Indicates that a formatted value acts as the predicate of a qualifier. |
44 | * |
45 | * @var string |
46 | */ |
47 | public const QUALIFIER_PREDICATE = 'qualifier-predicate'; |
48 | |
49 | /** |
50 | * Indicates that a formatted value is the property for a constraint parameter. |
51 | * |
52 | * @var string |
53 | */ |
54 | public const CONSTRAINT_PARAMETER_PROPERTY = 'constraint-parameter-property'; |
55 | |
56 | /** |
57 | * Indicates that a formatted value is the value for a constraint parameter. |
58 | * |
59 | * @var string |
60 | */ |
61 | public const CONSTRAINT_PARAMETER_VALUE = 'constraint-parameter-value'; |
62 | |
63 | /** |
64 | * Indicates that a formatted value is the item for a constraint type. |
65 | * |
66 | * @var string |
67 | */ |
68 | public const CONSTRAINT_TYPE_ITEM = 'constraint-type-item'; |
69 | |
70 | /** |
71 | * @codeCoverageIgnore |
72 | * @return never |
73 | */ |
74 | private function __construct() { |
75 | throw new LogicException( 'This class should never be instantiated.' ); |
76 | } |
77 | |
78 | } |