| Conditions | 3 |
| Paths | 3 |
| Total Lines | 14 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 3.072 |
| Changes | 0 | ||
| 1 | <?php |
||
| 49 | 4 | public function __toString(): string |
|
| 50 | { |
||
| 51 | 4 | switch ($this->getTypeCategory()) { |
|
| 52 | 4 | case self::CATEGORY_PK: |
|
| 53 | $format = '{type}{length}{comment}{check}{append}{pos}'; |
||
| 54 | break; |
||
| 55 | 4 | case self::CATEGORY_NUMERIC: |
|
| 56 | 3 | $format = '{type}{length}{unsigned}{notnull}{default}{unique}{comment}{append}{pos}{check}'; |
|
| 57 | 3 | break; |
|
| 58 | default: |
||
| 59 | 1 | $format = '{type}{length}{notnull}{default}{unique}{comment}{append}{pos}{check}'; |
|
| 60 | } |
||
| 61 | |||
| 62 | 4 | return $this->buildCompleteString($format); |
|
| 63 | } |
||
| 65 |