NmPrice.major constructor

NmPrice.major(
  1. num amount,
  2. String currency
)

From major units (e.g. NmPrice.major(897, 'RUB')).

Implementation

factory NmPrice.major(num amount, String currency) => NmPrice((amount * math10(_digits(currency))).round(), currency);