VersionedMessage class abstract
Abstract class representing a versioned message.
Constructors
-
VersionedMessage.fromBuffer(List<
int> serializedMessage) -
Constructs a versioned message from a serialized buffer.
factory
-
VersionedMessage.fromJson(Map<
String, dynamic> json, {TransactionType? type}) -
Constructs a version 0 versioned message.
factory
-
VersionedMessage.toLegacy({required SolAddress payerKey, required SolAddress recentBlockhash, required List<
TransactionInstruction> instructions}) -
Constructs a legacy versioned message.
factory
-
VersionedMessage.toV0({required SolAddress payerKey, required SolAddress recentBlockhash, required List<
TransactionInstruction> instructions, List<AddressLookupTableAccount> addressLookupTableAccounts = const []}) -
Constructs a version 0 versioned message.
factory
Properties
-
accountKeys
→ List<
SolAddress> -
All the account keys used by this transaction.
final
-
compiledInstructions
→ List<
CompiledInstruction> -
Instructions that will be executed in sequence and committed in one atomic transaction if all succeed..
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- header → MessageHeader
-
The message header, identifying signed and read-only accountKeys.
final
- recentBlockhash → SolAddress
-
The hash of a recent ledger block.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- version → TransactionType
-
Gets the version of the message.
no setter
Methods
-
copyWith(
{MessageHeader? header, List< SolAddress> ? accountKeys, SolAddress? recentBlockhash, List<CompiledInstruction> ? compiledInstructions, List<AddressTableLookup> ? addressTableLookups}) → VersionedMessage -
getAccounts(
{List< AddressLookupTableAccount> addressLookupTableAccounts = const [], AccountLookupKeys? lookupKeys}) → MessageAccountKeys - Gets the accounts associated with the message.
-
isAccountSigner(
int index) → bool - Checks if an account at the specified index is a signer.
-
isAccountWritable(
int index) → bool - Checks if an account at the specified index is writable.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
serialize(
) → List< int> - Serializes the message.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited