toLamports static method

BigInt toLamports(
  1. String value
)

Converts a Solana value in string format to lamports.

Implementation

static BigInt toLamports(String value) {
  final BigRational r = BigRational.parseDecimal(value);
  return (r * _decimalPlaces).toBigInt();
}