| Total Complexity | 5 |
| Total Lines | 35 |
| Duplicated Lines | 0 % |
| Coverage | 91.67% |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | final class FootnoteRef extends AbstractInline implements ReferenceableInterface |
||
| 22 | { |
||
| 23 | private ReferenceInterface $reference; |
||
| 24 | |||
| 25 | /** @psalm-readonly */ |
||
| 26 | private ?string $content = null; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * @param array<mixed> $data |
||
| 30 | */ |
||
| 31 | 94 | public function __construct(ReferenceInterface $reference, ?string $content = null, array $data = []) |
|
| 32 | { |
||
| 33 | 94 | parent::__construct(); |
|
| 34 | |||
| 35 | 94 | $this->reference = $reference; |
|
| 36 | 94 | $this->content = $content; |
|
| 37 | |||
| 38 | 94 | if (\count($data) > 0) { |
|
| 39 | $this->data->import($data); |
||
| 40 | } |
||
| 41 | } |
||
| 42 | |||
| 43 | 94 | public function getReference(): ReferenceInterface |
|
| 44 | { |
||
| 45 | 94 | return $this->reference; |
|
| 46 | } |
||
| 47 | |||
| 48 | 86 | public function setReference(ReferenceInterface $reference): void |
|
| 49 | { |
||
| 50 | 86 | $this->reference = $reference; |
|
| 51 | } |
||
| 52 | |||
| 53 | 86 | public function getContent(): ?string |
|
| 56 | } |
||
| 57 | } |
||
| 58 |