| Total Complexity | 4 |
| Total Lines | 37 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 24 | final class ConfigurationLogger |
||
| 25 | { |
||
| 26 | private $recommendations = []; |
||
| 27 | private $warnings = []; |
||
| 28 | |||
| 29 | public function addRecommendation(string $message): void |
||
| 30 | { |
||
| 31 | $message = trim($message); |
||
| 32 | |||
| 33 | Assertion::false('' === $message, 'Expected to have a message but a blank string was given instead.'); |
||
| 34 | |||
| 35 | $this->recommendations[$message] = $message; |
||
| 36 | } |
||
| 37 | |||
| 38 | /** |
||
| 39 | * @return string[] |
||
| 40 | */ |
||
| 41 | public function getRecommendations(): array |
||
| 42 | { |
||
| 43 | return array_keys($this->recommendations); |
||
| 44 | } |
||
| 45 | |||
| 46 | public function addWarning(string $message): void |
||
| 53 | } |
||
| 54 | |||
| 55 | /** |
||
| 56 | * @return string[] |
||
| 57 | */ |
||
| 58 | public function getWarnings(): array |
||
| 61 | } |
||
| 62 | } |
||
| 63 |