Files
hash-wallet/cw_core/lib/exceptions.dart
T
David AdegokeandGitHub ea4d752914 solana nft improvements and other fixes (#3581)
* feat: improvements covering solana nfts(send, ownership badge, persistent imports etc), closing emptied token accounts and other fixes from patch

* feat: more improvements for nfts including security hardening

* fix: display error in full
2026-09-03 01:54:11 +08:00

90 lines
2.3 KiB
Dart

import 'package:cw_core/crypto_currency.dart';
class TransactionWrongBalanceException implements Exception {
TransactionWrongBalanceException(this.currency, {this.amount});
final CryptoCurrency currency;
final int? amount;
}
class TransactionNoInputsException implements Exception {}
class TransactionNoFeeException implements Exception {}
class TransactionNoDustException implements Exception {}
class TransactionNoDustOnChangeException implements Exception {
TransactionNoDustOnChangeException(this.max, this.min);
final String max;
final String min;
}
class TransactionCommitFailed implements Exception {
final String? errorMessage;
TransactionCommitFailed({this.errorMessage});
@override
String toString() => errorMessage ?? "unknown error";
}
class TransactionCommitFailedDustChange implements Exception {}
class TransactionCommitFailedDustOutput implements Exception {}
class TransactionCommitFailedDustOutputSendAll implements Exception {}
class TransactionCommitFailedVoutNegative implements Exception {}
class TransactionCommitFailedBIP68Final implements Exception {}
class TransactionCommitFailedLessThanMin implements Exception {}
class TransactionInputNotSupported implements Exception {}
class SignNativeTokenTransactionRentException implements Exception {}
class CreateAssociatedTokenAccountException implements Exception {
final String errorMessage;
CreateAssociatedTokenAccountException(this.errorMessage);
}
class SignSPLTokenTransactionRentException implements Exception {}
class NoAssociatedTokenAccountException implements Exception {}
class NotAnNFTException implements Exception {}
class AmbiguousTokenSymbolException implements Exception {
AmbiguousTokenSymbolException(this.symbol);
final String symbol;
}
class RestoreFromSeedException implements Exception {
final String message;
RestoreFromSeedException(this.message);
}
class WalletDeprecationException implements Exception {
final String seed;
final CryptoCurrency curr;
@override
String toString() => "Wallet type no longer supported";
WalletDeprecationException({required this.seed, required this.curr});
}
class WalletSwitchException implements Exception {
WalletSwitchException(this.message);
final String message;
@override
String toString() => message;
}