mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-11-17 01:37:40 +00:00
98a9edc656
* fix nano sending, update restore page wording, and other minor fixes * fix bch address parsing * minor code enhancement [skip ci] * Register the main secure storage as the long lived instance of secure storage throughout the app session --------- Co-authored-by: Serhii <borodenko.sv@gmail.com> Co-authored-by: OmarHatem <omarh.ismail1@gmail.com>
42 lines
1.1 KiB
Dart
42 lines
1.1 KiB
Dart
import 'package:cw_core/wallet_credentials.dart';
|
|
import 'package:cw_core/wallet_info.dart';
|
|
|
|
class NanoNewWalletCredentials extends WalletCredentials {
|
|
NanoNewWalletCredentials({required String name, String? password})
|
|
: super(name: name, password: password);
|
|
}
|
|
|
|
class NanoRestoreWalletFromSeedCredentials extends WalletCredentials {
|
|
NanoRestoreWalletFromSeedCredentials({
|
|
required String name,
|
|
required this.mnemonic,
|
|
String? password,
|
|
DerivationType? derivationType,
|
|
}) : super(
|
|
name: name,
|
|
password: password,
|
|
derivationType: derivationType,
|
|
);
|
|
|
|
final String mnemonic;
|
|
}
|
|
|
|
class NanoWalletLoadingException implements Exception {
|
|
@override
|
|
String toString() => 'Failure to load the wallet.';
|
|
}
|
|
|
|
class NanoRestoreWalletFromKeysCredentials extends WalletCredentials {
|
|
NanoRestoreWalletFromKeysCredentials({
|
|
required String name,
|
|
required String password,
|
|
required this.seedKey,
|
|
DerivationType? derivationType,
|
|
}) : super(
|
|
name: name,
|
|
password: password,
|
|
derivationType: derivationType,
|
|
);
|
|
|
|
final String seedKey;
|
|
}
|