Options
All
  • Public
  • Public/Protected
  • All
Menu

Factory class for transactions to interact with a program loader

Hierarchy

  • BpfLoader

Index

Constructors

Methods

  • getMinNumSignatures(dataLength: number): number
  • Minimum number of signatures required to load a program not including retries

    Can be used to calculate transaction fees

    Parameters

    • dataLength: number

    Returns number

  • Load a SBF program

    Parameters

    • connection: Connection

      The connection to use

    • payer: Signer

      Account that will pay program loading fees

    • program: Signer

      Account to load the program into

    • elf: number[] | Uint8Array | Buffer

      The entire ELF containing the SBF program

    • loaderProgramId: PublicKey

      The program id of the BPF loader to use

    Returns Promise<boolean>

    true if program was loaded successfully, false if program was already loaded

Generated using TypeDoc