mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-22 19:49:22 +00:00
4b4d8a4840
* Add passphrase support for Eth, Polygon, and Tron * move passphrase to advanced settings even for restore
48 lines
1.3 KiB
Dart
48 lines
1.3 KiB
Dart
import 'package:cw_core/wallet_credentials.dart';
|
|
import 'package:cw_core/wallet_info.dart';
|
|
|
|
class SolanaNewWalletCredentials extends WalletCredentials {
|
|
SolanaNewWalletCredentials({
|
|
required String name,
|
|
WalletInfo? walletInfo,
|
|
String? password,
|
|
String? parentAddress,
|
|
this.mnemonic,
|
|
String? passphrase,
|
|
}) : super(
|
|
name: name,
|
|
walletInfo: walletInfo,
|
|
password: password,
|
|
parentAddress: parentAddress,
|
|
passphrase: passphrase,
|
|
);
|
|
final String? mnemonic;
|
|
}
|
|
|
|
class SolanaRestoreWalletFromSeedCredentials extends WalletCredentials {
|
|
SolanaRestoreWalletFromSeedCredentials({
|
|
required String name,
|
|
required String password,
|
|
required this.mnemonic,
|
|
WalletInfo? walletInfo,
|
|
String? passphrase,
|
|
}) : super(
|
|
name: name,
|
|
password: password,
|
|
walletInfo: walletInfo,
|
|
passphrase: passphrase,
|
|
);
|
|
|
|
final String mnemonic;
|
|
}
|
|
|
|
class SolanaRestoreWalletFromPrivateKey extends WalletCredentials {
|
|
SolanaRestoreWalletFromPrivateKey(
|
|
{required String name,
|
|
required String password,
|
|
required this.privateKey,
|
|
WalletInfo? walletInfo})
|
|
: super(name: name, password: password, walletInfo: walletInfo);
|
|
|
|
final String privateKey;
|
|
}
|