ledger-core
|
Public Member Functions | |
BigIntImpl (const ledger::core::BigInt &v) | |
virtual std::shared_ptr< ledger::core::api::BigInt > | add (const std::shared_ptr< ledger::core::api::BigInt > &i) override |
virtual std::shared_ptr< ledger::core::api::BigInt > | subtract (const std::shared_ptr< ledger::core::api::BigInt > &i) override |
virtual std::shared_ptr< ledger::core::api::BigInt > | multiply (const std::shared_ptr< ledger::core::api::BigInt > &i) override |
virtual std::shared_ptr< ledger::core::api::BigInt > | divide (const std::shared_ptr< ledger::core::api::BigInt > &i) override |
virtual std::vector< std::shared_ptr< ledger::core::api::BigInt > > | divideAndRemainder (const std::shared_ptr< ledger::core::api::BigInt > &i) override |
virtual std::shared_ptr< ledger::core::api::BigInt > | pow (int32_t exponent) override |
virtual std::string | toDecimalString (int32_t precision, const std::string &decimalSeparator, const std::string &thousandSeparator) override |
virtual int32_t | intValue () override |
virtual int32_t | compare (const std::shared_ptr< ledger::core::api::BigInt > &i) override |
virtual std::string | toString (int32_t radix) override |
![]() | |
virtual std::shared_ptr< BigInt > | add (const std::shared_ptr< BigInt > &i)=0 |
virtual std::shared_ptr< BigInt > | subtract (const std::shared_ptr< BigInt > &i)=0 |
virtual std::shared_ptr< BigInt > | multiply (const std::shared_ptr< BigInt > &i)=0 |
virtual std::shared_ptr< BigInt > | divide (const std::shared_ptr< BigInt > &i)=0 |
virtual std::vector< std::shared_ptr< BigInt > > | divideAndRemainder (const std::shared_ptr< BigInt > &i)=0 |
virtual int32_t | compare (const std::shared_ptr< BigInt > &i)=0 |
Additional Inherited Members | |
![]() | |
static std::shared_ptr< BigInt > | fromDecimalString (const std::string &s, int32_t precision, const std::string &decimalSeparator) |
static std::shared_ptr< BigInt > | fromIntegerString (const std::string &s, int32_t radix) |
static std::shared_ptr< BigInt > | fromLong (int64_t l) |
|
overridevirtual |
Returns the int representation of this BigInt. Note that if the BigInt is greater than 4 bytes the returned value will be meaningless.
Implements ledger::core::api::BigInt.
|
overridevirtual |
Raises this BigInt with an interger value. i The exponent to which thi BigInt is raised
Implements ledger::core::api::BigInt.
|
overridevirtual |
Formats this BigInt to a decimal string (e.g. BigInt("12345").toDecimalString(1, ".", ",") => "1,234.5"). precision The power of ten by wich this BigInt is divided decimalSeparator The separator to use between the integer part and the decimal part thousandSeparator The separator to use between each group of thousand units
Implements ledger::core::api::BigInt.
|
overridevirtual |
Formats this BigInt to the interger representation of its internal value. radix The radix of the number representation in which to format (right now 10 or 16)
Implements ledger::core::api::BigInt.