Total Complexity | 8 |
Total Lines | 40 |
Duplicated Lines | 0 % |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
7 | class SchemaEnumAttribute extends SchemaAttribute |
||
8 | { |
||
9 | protected array $values; |
||
10 | |||
11 | public function __construct(Schema $schema, string $name) |
||
12 | { |
||
13 | parent::__construct($schema, $name); |
||
14 | $this->values = []; |
||
15 | } |
||
16 | |||
17 | public function values(array $values): self |
||
18 | { |
||
19 | $this->values = $values; |
||
20 | return $this; |
||
21 | } |
||
22 | |||
23 | private function matchesLoose($value) |
||
26 | } |
||
27 | |||
28 | public function parseContextual($value) |
||
37 | } |
||
38 | |||
39 | private function getValuesVerbose(): string |
||
40 | { |
||
41 | return implode(', ', $this->values); |
||
42 | } |
||
43 | |||
44 | public static function from(Schema $schema, string $name): self |
||
47 | } |
||
48 | } |