TonWalletState class

State of TonWallet that allows tracking when subscription was created successfully or when it failed with some error.

To detect which state is active, use hasWallet and hasError.

Annotations

Constructors

TonWalletState.error({required Object err, required Address address})
Create state with error.
const
TonWalletState.wallet(TonWallet w)
Create state with wallet

Properties

address Address
Allows to track for which wallet this state was created. This can be useful when wallet is null and we cannot detect it.
final
error Object?
Any error that could be thrown during creating subscription.
final
hasError bool
no setter
hashCode int
The hash code for this object.
no setterinherited
hasWallet bool
no setter
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stringify bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited
wallet TonWallet?
Wallet that could be created. If wallet was created, then hasWallet returns true and you can use it as usual.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited