|
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
|
Public Member Functions | |
| init ($operand, $base=10) | |
| add ($left_operand, $right_operand) | |
| subtract ($left_operand, $right_operand) | |
| compare ($left_operand, $right_operand) | |
| divide ($left_operand, $right_operand) | |
| modulus ($left_operand, $modulus) | |
| multiply ($left_operand, $right_operand) | |
| pow ($left_operand, $right_operand) | |
| powmod ($left_operand, $right_operand, $modulus) | |
| sqrt ($operand) | |
| binaryToInteger ($operand) | |
| integerToBinary ($operand) | |
| hexToDecimal ($operand) | |
| add | ( | $left_operand, | |
| $right_operand | |||
| ) |
Adds two arbitrary precision numbers
| resource | $left_operand | |
| resource | $right_operand |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 60 of file Gmp.php.
| binaryToInteger | ( | $operand | ) |
| string | $operand |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 178 of file Gmp.php.
| compare | ( | $left_operand, | |
| $right_operand | |||
| ) |
Compare two big integers and returns result as an integer where 0 means both are identical, 1 that left_operand is larger, or -1 that right_operand is larger.
| resource | $left_operand | |
| resource | $right_operand |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 88 of file Gmp.php.
| divide | ( | $left_operand, | |
| $right_operand | |||
| ) |
Divide two big integers and return result or NULL if the denominator is zero.
| resource | $left_operand | |
| resource | $right_operand |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 102 of file Gmp.php.
| hexToDecimal | ( | $operand | ) |
| init | ( | $operand, | |
$base = 10 |
|||
| ) |
Initialise a big integer into an extension specific type.
| string | $operand | |
| int | $base |
Implements Zend_Crypt_Math_BigInteger_Interface.
| integerToBinary | ( | $operand | ) |
| resource | $operand | GMP number resource |
Implements Zend_Crypt_Math_BigInteger_Interface.
| modulus | ( | $left_operand, | |
| $modulus | |||
| ) |
Modulo operation
| resource | $left_operand | |
| resource | $modulus |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 116 of file Gmp.php.
| multiply | ( | $left_operand, | |
| $right_operand | |||
| ) |
Multiply numbers
| resource | $left_operand | |
| resource | $right_operand |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 129 of file Gmp.php.
| pow | ( | $left_operand, | |
| $right_operand | |||
| ) |
Raise number into power
| resource | $left_operand | |
| int | $right_operand |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 142 of file Gmp.php.
| powmod | ( | $left_operand, | |
| $right_operand, | |||
| $modulus | |||
| ) |
Raise number into power with modulo
| resource | $left_operand | |
| resource | $right_operand | |
| resource | $modulus |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 156 of file Gmp.php.
| sqrt | ( | $operand | ) |
Calculate square root
| $operand |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 168 of file Gmp.php.
| subtract | ( | $left_operand, | |
| $right_operand | |||
| ) |
Subtract numbers
| resource | $left_operand | |
| resource | $right_operand |
Implements Zend_Crypt_Math_BigInteger_Interface.
Definition at line 73 of file Gmp.php.