CurrencyAmount.fromFractionalAmount constructor

CurrencyAmount.fromFractionalAmount(
  1. Currency currency,
  2. BigInt numerator,
  3. BigInt denominator
)

Construct a currency amount with a denominator that is not equal to 1 @param currency the currency @param numerator the numerator of the fractional token amount @param denominator the denominator of the fractional token amount

Implementation

factory CurrencyAmount.fromFractionalAmount(
  Currency currency,
  BigInt numerator,
  BigInt denominator,
) {
  return CurrencyAmount(currency, numerator, denominator: denominator);
}