| Total Complexity | 3 |
| Total Lines | 36 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 7 | class Relation implements \Stringable |
||
| 8 | { |
||
| 9 | use StringFormatter; |
||
| 10 | |||
| 11 | private const BLOCK = '%s %s %s : %s'; |
||
| 12 | |||
| 13 | private string $parent; |
||
| 14 | |||
| 15 | private string $children; |
||
| 16 | |||
| 17 | private string $comment; |
||
| 18 | |||
| 19 | private string $arrow; |
||
| 20 | private bool $isNullable; |
||
| 21 | |||
| 22 | public function __construct( |
||
| 23 | string $parent, |
||
| 24 | string $children, |
||
| 25 | string $comment, |
||
| 26 | string $arrow, |
||
| 27 | bool $isNullable |
||
| 28 | ) { |
||
| 29 | $this->parent = $this->resolveString($parent); |
||
| 30 | $this->children = $this->resolveString($children); |
||
| 31 | $this->comment = $comment; |
||
| 32 | $this->arrow = $arrow; |
||
| 33 | $this->isNullable = $isNullable; |
||
| 34 | } |
||
| 35 | |||
| 36 | public function __toString(): string |
||
| 43 | } |
||
| 44 | } |
||
| 45 |