@@ -71,11 +71,11 @@ |
||
| 71 | 71 | $num = $this->_number->gmpObj(); |
| 72 | 72 | switch (gmp_sign($num)) { |
| 73 | 73 | // positive |
| 74 | - case 1: |
|
| 75 | - return self::_encodePositiveInteger($num); |
|
| 76 | - // negative |
|
| 77 | - case -1: |
|
| 78 | - return self::_encodeNegativeInteger($num); |
|
| 74 | + case 1: |
|
| 75 | + return self::_encodePositiveInteger($num); |
|
| 76 | + // negative |
|
| 77 | + case -1: |
|
| 78 | + return self::_encodeNegativeInteger($num); |
|
| 79 | 79 | } |
| 80 | 80 | // zero |
| 81 | 81 | return "\0"; |
@@ -349,10 +349,10 @@ discard block |
||
| 349 | 349 | private function _isPseudoType(int $tag): bool |
| 350 | 350 | { |
| 351 | 351 | switch ($tag) { |
| 352 | - case self::TYPE_STRING: |
|
| 353 | - return $this instanceof StringType; |
|
| 354 | - case self::TYPE_TIME: |
|
| 355 | - return $this instanceof TimeType; |
|
| 352 | + case self::TYPE_STRING: |
|
| 353 | + return $this instanceof StringType; |
|
| 354 | + case self::TYPE_TIME: |
|
| 355 | + return $this instanceof TimeType; |
|
| 356 | 356 | } |
| 357 | 357 | return false; |
| 358 | 358 | } |
@@ -439,20 +439,20 @@ discard block |
||
| 439 | 439 | protected static function _determineImplClass(Identifier $identifier): string |
| 440 | 440 | { |
| 441 | 441 | switch ($identifier->typeClass()) { |
| 442 | - case Identifier::CLASS_UNIVERSAL: |
|
| 443 | - $cls = self::_determineUniversalImplClass($identifier->intTag()); |
|
| 444 | - // constructed strings may be present in BER |
|
| 445 | - if ($identifier->isConstructed() && |
|
| 446 | - is_subclass_of($cls, PrimitiveString::class)) { |
|
| 447 | - $cls = ConstructedString::class; |
|
| 448 | - } |
|
| 449 | - return $cls; |
|
| 450 | - case Identifier::CLASS_CONTEXT_SPECIFIC: |
|
| 451 | - return ContextSpecificType::class; |
|
| 452 | - case Identifier::CLASS_APPLICATION: |
|
| 453 | - return ApplicationType::class; |
|
| 454 | - case Identifier::CLASS_PRIVATE: |
|
| 455 | - return PrivateType::class; |
|
| 442 | + case Identifier::CLASS_UNIVERSAL: |
|
| 443 | + $cls = self::_determineUniversalImplClass($identifier->intTag()); |
|
| 444 | + // constructed strings may be present in BER |
|
| 445 | + if ($identifier->isConstructed() && |
|
| 446 | + is_subclass_of($cls, PrimitiveString::class)) { |
|
| 447 | + $cls = ConstructedString::class; |
|
| 448 | + } |
|
| 449 | + return $cls; |
|
| 450 | + case Identifier::CLASS_CONTEXT_SPECIFIC: |
|
| 451 | + return ContextSpecificType::class; |
|
| 452 | + case Identifier::CLASS_APPLICATION: |
|
| 453 | + return ApplicationType::class; |
|
| 454 | + case Identifier::CLASS_PRIVATE: |
|
| 455 | + return PrivateType::class; |
|
| 456 | 456 | } |
| 457 | 457 | throw new \UnexpectedValueException( |
| 458 | 458 | sprintf("%s %d not implemented.", |