You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: lib/model/coin.dart
+21-1
Original file line number
Diff line number
Diff line change
@@ -62,12 +62,20 @@ class Coin {
62
62
CexPrice? usdPrice;
63
63
finalbool isTestCoin;
64
64
bool isCustomCoin;
65
+
66
+
@Deprecated('$_urgentDeprecationNotice Use the SDK\'s Asset multi-address support instead. The wallet now works with multiple addresses per account.')
65
67
String? address;
68
+
69
+
@Deprecated('$_urgentDeprecationNotice Use the SDK\'s Asset account management instead.')
66
70
List<HdAccount>? accounts;
71
+
67
72
finaldouble _balance;
68
73
finalString? _swapContractAddress;
69
74
String? fallbackSwapContract;
75
+
76
+
@Deprecated('$_urgentDeprecationNotice Use the SDK\'s WalletManager to determine wallet type.')
70
77
WalletType? enabledType;
78
+
71
79
finalbool _walletOnly;
72
80
finalint priority;
73
81
Coin? parentCoin;
@@ -83,9 +91,10 @@ class Coin {
83
91
boolget isActivating => state ==CoinState.activating;
84
92
boolget isInactive => state ==CoinState.inactive;
85
93
94
+
@Deprecated('$_urgentDeprecationNotice Use the SDK\'s Asset.sendableBalance instead. This value is not updated after initial load and may be inaccurate.')
86
95
double sendableBalance =0;
87
96
88
-
@Deprecated('Use the balance manager from the SDK')
97
+
@Deprecated('$_urgentDeprecationNoticeUse the balance manager from the SDK. This balance value is not updated after initial load and may be inaccurate.')
89
98
doubleget balance {
90
99
switch (enabledType) {
91
100
caseWalletType.trezor:
@@ -95,6 +104,7 @@ class Coin {
95
104
}
96
105
}
97
106
107
+
@Deprecated('$_urgentDeprecationNotice Use the SDK\'s Asset balance tracking instead. This balance value is not updated after initial load and may be inaccurate.')
98
108
double?get _totalHdBalance {
99
109
if (accounts ==null) returnnull;
100
110
@@ -115,6 +125,7 @@ class Coin {
115
125
return amount * usdPrice!.price;
116
126
}
117
127
128
+
@Deprecated('$_urgentDeprecationNotice Use the SDK\'s Asset price and balance methods instead. This value uses potentially outdated balance and price information.')
@Deprecated('TODO: Adapt SDK to cater for this use case and remove this method.')
144
157
String?get defaultAddress {
145
158
switch (enabledType) {
146
159
caseWalletType.trezor:
@@ -165,6 +178,7 @@ class Coin {
165
178
returnfalse;
166
179
}
167
180
181
+
@Deprecated('TODO: Adapt SDK to cater for this use case and remove this method.')
168
182
String?get _defaultTrezorAddress {
169
183
if (enabledType !=WalletType.trezor) returnnull;
170
184
if (accounts ==null) returnnull;
@@ -174,6 +188,7 @@ class Coin {
174
188
return accounts!.first.addresses.first.address;
175
189
}
176
190
191
+
@Deprecated('$_urgentDeprecationNotice Use the SDK\'s Asset address management instead. This value is not updated after initial load and may be inaccurate.')
0 commit comments