function BigRational::__unserialize
This method is only here to allow unserializing the object and cannot be accessed directly.
@internal @psalm-suppress RedundantPropertyInitializationCheck
Parameters
array{numerator: BigInteger, denominator: BigInteger} $data:
Throws
\LogicException
File
-
vendor/
brick/ math/ src/ BigRational.php, line 404
Class
- BigRational
- An arbitrarily large rational number.
Namespace
Brick\MathCode
public function __unserialize(array $data) : void {
if (isset($this->numerator)) {
throw new \LogicException('__unserialize() is an internal function, it must not be called directly.');
}
$this->numerator = $data['numerator'];
$this->denominator = $data['denominator'];
}