| Total Complexity | 3 |
| Total Lines | 21 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 7 | abstract class AbstractFormatter implements FormatterInterface |
||
| 8 | { |
||
| 9 | /** @var int */ |
||
| 10 | protected $options = 0; |
||
| 11 | |||
| 12 | /** {@inheritDoc} */ |
||
| 13 | public function __construct(?int $options = null) |
||
| 14 | { |
||
| 15 | $this->options = $options ?? 0; |
||
| 16 | } |
||
| 17 | |||
| 18 | abstract public function process(Formattable $data): string; |
||
| 19 | |||
| 20 | /** |
||
| 21 | * @param Formattable $data |
||
| 22 | * @param string $class |
||
| 23 | */ |
||
| 24 | protected function assertData(Formattable $data, string $class): void |
||
| 28 | } |
||
| 29 | } |
||
| 31 |