Lines
0.00%
0 / 3
Functions and Methods
0.00%
0 / 3
Classes and Traits
0.00%
0 / 1
| Name | Lines | Functions and Methods | CRAP | Classes and Traits | ||||||
|---|---|---|---|---|---|---|---|---|---|---|
| LiveTrigger | 0.00% | 0 / 3 | 0.00% | 0 / 3 | 12 | 0.00% | 0 / 1 | |||
| __construct | 0.00% | 0 / 1 | 0.00% | 0 / 1 | 2 | |||||
| recordHaSubscriptionId | 0.00% | 0 / 1 | 0.00% | 0 / 1 | 2 | |||||
| forgetHaSubscriptionId | 0.00% | 0 / 1 | 0.00% | 0 / 1 | 2 | |||||
| 1 | <?php | |
| 2 | ||
| 3 | declare(strict_types=1); | |
| 4 | ||
| 5 | namespace Stewart\Runtime\Broker\Trigger; | |
| 6 | ||
| 7 | use Stewart\Support\Wire\TriggerSpec; | |
| 8 | ||
| 9 | final class LiveTrigger | |
| 10 | { | |
| 11 | public private(set) ?int $haSubscriptionId = null; | |
| 12 | ||
| 13 | public function __construct(public readonly TriggerSpec $spec) {} | |
| 14 | ||
| 15 | public function recordHaSubscriptionId(int $haSubscriptionId): void | |
| 16 | { | |
| 17 | $this->haSubscriptionId = $haSubscriptionId; | |
| 18 | } | |
| 19 | ||
| 20 | public function forgetHaSubscriptionId(): void | |
| 21 | { | |
| 22 | $this->haSubscriptionId = null; | |
| 23 | } | |
| 24 | } |