Solana.Transaction (Solana v0.1.1) View Source
Functions for building and encoding Solana transactions
Link to this section Summary
Types
The possible errors encountered when encoding a transaction.
All the details needed to encode a transaction.
Functions
Checks to see if a transaction's signature is valid.
Encodes a Solana.Transaction.t/0
into a binary
format
Link to this section Types
Specs
encoding_err() :: :no_payer | :no_blockhash | :no_program | :no_instructions | :mismatched_signers
The possible errors encountered when encoding a transaction.
Specs
t() :: %Solana.Transaction{ blockhash: binary() | nil, instructions: [Solana.Instruction.t()], payer: Solana.key() | nil, signers: [Solana.keypair()] }
All the details needed to encode a transaction.
Link to this section Functions
Specs
Checks to see if a transaction's signature is valid.
Returns {:ok, signature}
if it is, and an error tuple if it isn't.
Specs
to_binary(tx :: t()) :: {:ok, binary()} | {:error, encoding_err()}
Encodes a Solana.Transaction.t/0
into a binary
format
Returns {:ok, encoded_transaction}
if the transaction was successfully
encoded, or an error tuple if the encoding failed -- plus more error details
via Logger.error/1
.