SPLTokenProgram.initializeAccount3 constructor

SPLTokenProgram.initializeAccount3({
  1. required SPLTokenInitializeAccount3Layout layout,
  2. required SolAddress account,
  3. required SolAddress mint,
  4. SolAddress programId = SPLTokenProgramConst.tokenProgramId,
})

Like InitializeAccount2, but does not require the Rent sysvar to be provided

Implementation

factory SPLTokenProgram.initializeAccount3(
    {required SPLTokenInitializeAccount3Layout layout,

    /// The account to initialize.
    required SolAddress account,

    /// The mint this account will be associated with.
    required SolAddress mint,
    SolAddress programId = SPLTokenProgramConst.tokenProgramId}) {
  return SPLTokenProgram(
      layout: layout,
      keys: [
        account.toWritable(),
        mint.toReadOnly(),
      ],
      programId: programId);
}