Total Complexity | 3 |
Total Lines | 26 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php declare(strict_types=1); |
||
8 | #[Package('content')] |
||
9 | class UnusedMediaSearchEvent extends Event |
||
10 | { |
||
11 | /** |
||
12 | * @param array<string> $ids |
||
13 | */ |
||
14 | public function __construct(private array $ids) |
||
15 | { |
||
16 | } |
||
17 | |||
18 | /** |
||
19 | * Specify that some IDs should NOT be deleted, they are in fact used. |
||
20 | * |
||
21 | * @param array<string> $ids |
||
22 | */ |
||
23 | public function markAsUsed(array $ids): void |
||
24 | { |
||
25 | $this->ids = array_values(array_diff($this->ids, $ids)); |
||
26 | } |
||
27 | |||
28 | /** |
||
29 | * @return array<string> $ids |
||
30 | */ |
||
31 | public function getUnusedIds(): array |
||
34 | } |
||
35 | } |
||
36 |