mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-23 12:09:43 +00:00
20 lines
No EOL
788 B
Dart
20 lines
No EOL
788 B
Dart
import 'package:flutter/foundation.dart';
|
|
import 'package:cake_wallet/src/domain/monero/monero_amount_format.dart';
|
|
|
|
class MoneroBalance {
|
|
MoneroBalance({@required this.fullBalance, @required this.unlockedBalance})
|
|
: formattedFullBalance = moneroAmountToString(amount: fullBalance),
|
|
formattedUnlockedBalance =
|
|
moneroAmountToString(amount: unlockedBalance);
|
|
|
|
MoneroBalance.fromString(
|
|
{@required this.formattedFullBalance,
|
|
@required this.formattedUnlockedBalance})
|
|
: fullBalance = moneroParseAmount(amount: formattedFullBalance),
|
|
unlockedBalance = moneroParseAmount(amount: formattedUnlockedBalance);
|
|
|
|
final int fullBalance;
|
|
final int unlockedBalance;
|
|
final String formattedFullBalance;
|
|
final String formattedUnlockedBalance;
|
|
} |