| Conditions | 2 |
| Paths | 2 |
| Total Lines | 25 |
| Code Lines | 21 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 21 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 34 | 158 | private static function init(): void |
|
| 35 | { |
||
| 36 | 158 | if (!\is_null(self::$symbols)) { |
|
| 37 | 158 | return; |
|
| 38 | } |
||
| 39 | |||
| 40 | 2 | self::$symbols = Map::of('string', 'string') |
|
| 41 | 2 | ('b', SignedOctet::class) |
|
| 42 | 2 | ('B', UnsignedOctet::class) |
|
| 43 | 2 | ('U', SignedShortInteger::class) |
|
| 44 | 2 | ('u', UnsignedShortInteger::class) |
|
| 45 | 2 | ('I', SignedLongInteger::class) |
|
| 46 | 2 | ('i', UnsignedLongInteger::class) |
|
| 47 | 2 | ('L', SignedLongLongInteger::class) |
|
| 48 | 2 | ('l', UnsignedLongLongInteger::class) |
|
| 49 | 2 | ('D', Decimal::class) |
|
| 50 | 2 | ('T', Timestamp::class) |
|
| 51 | 2 | ('V', VoidValue::class) |
|
| 52 | 2 | ('t', Bits::class) |
|
| 53 | 2 | ('s', ShortString::class) |
|
| 54 | 2 | ('S', LongString::class) |
|
| 55 | 2 | ('A', Sequence::class) |
|
| 56 | 2 | ('F', Table::class); |
|
| 57 | self::$classes = self::$symbols->map(static function(string $symbol, string $class): Pair { |
||
| 58 | 2 | return new Pair($class, $symbol); |
|
| 59 | 2 | }); |
|
| 62 |