| Total Complexity | 5 |
| Total Lines | 24 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 28 | class StateCollection |
||
| 29 | { |
||
| 30 | use CollectionTrait; |
||
| 31 | |||
| 32 | protected function describeItem(): string |
||
| 35 | } |
||
| 36 | |||
| 37 | public function __construct(StateInterface ...$states) |
||
| 38 | { |
||
| 39 | foreach ($states as $state) { |
||
| 40 | $this->addState($state); |
||
| 41 | } |
||
| 42 | } |
||
| 43 | |||
| 44 | public function addState(StateInterface $state): void |
||
| 47 | } |
||
| 48 | |||
| 49 | public function getState(string $stateId): StateInterface |
||
| 54 |