| Total Complexity | 4 |
| Total Lines | 25 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 10 | final class SignedLongLongInteger implements Value |
||
| 11 | { |
||
| 12 | private $value; |
||
| 13 | private $original; |
||
| 14 | |||
| 15 | 26 | public function __construct(Integer $value) |
|
| 16 | { |
||
| 17 | 26 | $this->original = $value; |
|
| 18 | 26 | } |
|
| 19 | |||
| 20 | 12 | public static function fromStream(Readable $stream): Value |
|
| 21 | { |
||
| 22 | 12 | [, $value] = \unpack('q', (string) $stream->read(8)); |
|
| 23 | |||
| 24 | 12 | return new self(new Integer($value)); |
|
| 25 | } |
||
| 26 | |||
| 27 | 24 | public function original(): Integer |
|
| 30 | } |
||
| 31 | |||
| 32 | 24 | public function __toString(): string |
|
| 37 |