Account class abstract
An account
- Available extensions
- Annotations
-
- @freezed
Constructors
- Account({required int lamports, required String owner, required AccountData? data, required bool executable, @JsonKey.new(fromJson: bigIntFromJson) required BigInt rentEpoch})
-
constfactory
-
Account.fromJson(Map<
String, dynamic> json) -
factory
Properties
-
copyWith
→ $AccountCopyWith<
Account> -
Create a copy of Account
with the given fields replaced by the non-null parameter values.
no setterinherited
- data → AccountData?
-
Data associated with the account, either as encoded binary
data or JSON format {program: state}, depending on
encoding parameter
no setterinherited
- executable → bool
-
Boolean indicating if the account contains a program (and
is strictly read-only)
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- lamports → int
-
Number of lamports assigned to this account, as a u64
no setterinherited
- owner → String
-
base-58 encoded Pubkey of the program this account has been
assigned to
no setterinherited
- rentEpoch → BigInt
-
The epoch at which this account will next owe rent, as u64
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
map<
TResult extends Object?> (TResult $default(_Account value)) → TResult -
Available on Account, provided by the AccountPatterns extension
Aswitch-like method, using callbacks. -
mapOrNull<
TResult extends Object?> (TResult? $default(_Account value)?) → TResult? -
Available on Account, provided by the AccountPatterns extension
A variant ofmapthat fallback to returningnull. -
maybeMap<
TResult extends Object?> (TResult $default(_Account value)?, {required TResult orElse()}) → TResult -
Available on Account, provided by the AccountPatterns extension
A variant ofmapthat fallback to returningorElse. -
maybeWhen<
TResult extends Object?> (TResult $default(int lamports, String owner, AccountData? data, bool executable, BigInt rentEpoch)?, {required TResult orElse()}) → TResult -
Available on Account, provided by the AccountPatterns extension
A variant ofwhenthat fallback to anorElsecallback. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
Serializes this Account to a JSON map.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
when<
TResult extends Object?> (TResult $default(int lamports, String owner, AccountData? data, bool executable, BigInt rentEpoch)) → TResult -
Available on Account, provided by the AccountPatterns extension
Aswitch-like method, using callbacks. -
whenOrNull<
TResult extends Object?> (TResult? $default(int lamports, String owner, AccountData? data, bool executable, BigInt rentEpoch)?) → TResult? -
Available on Account, provided by the AccountPatterns extension
A variant ofwhenthat fallback to returningnull
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited