MetaplexAuctionHouseProgram.auctioneerBuy constructor

MetaplexAuctionHouseProgram.auctioneerBuy({
  1. required MetaplexAuctionHouseAuctioneerBuyLayout layout,
  2. required SolAddress wallet,
  3. required SolAddress paymentAccount,
  4. required SolAddress transferAuthority,
  5. required SolAddress treasuryMint,
  6. required SolAddress tokenAccount,
  7. required SolAddress metadata,
  8. required SolAddress escrowPaymentAccount,
  9. required SolAddress authority,
  10. required SolAddress auctioneerAuthority,
  11. required SolAddress auctionHouse,
  12. required SolAddress auctionHouseFeeAccount,
  13. required SolAddress buyerTradeState,
  14. required SolAddress ahAuctioneerPda,
  15. SolAddress tokenProgram = SPLTokenProgramConst.tokenProgramId,
  16. SolAddress systemProgram = SystemProgramConst.programId,
  17. SolAddress rent = SystemProgramConst.sysvarRentPubkey,
})

Implementation

factory MetaplexAuctionHouseProgram.auctioneerBuy({
  required MetaplexAuctionHouseAuctioneerBuyLayout layout,
  required SolAddress wallet,
  required SolAddress paymentAccount,
  required SolAddress transferAuthority,
  required SolAddress treasuryMint,
  required SolAddress tokenAccount,
  required SolAddress metadata,
  required SolAddress escrowPaymentAccount,
  required SolAddress authority,
  required SolAddress auctioneerAuthority,
  required SolAddress auctionHouse,
  required SolAddress auctionHouseFeeAccount,
  required SolAddress buyerTradeState,
  required SolAddress ahAuctioneerPda,
  SolAddress tokenProgram = SPLTokenProgramConst.tokenProgramId,
  SolAddress systemProgram = SystemProgramConst.programId,
  SolAddress rent = SystemProgramConst.sysvarRentPubkey,
}) {
  return MetaplexAuctionHouseProgram(keys: [
    wallet.toWritable(),
    paymentAccount.toWritable(),
    transferAuthority.toReadOnly(),
    treasuryMint.toReadOnly(),
    tokenAccount.toReadOnly(),
    metadata.toReadOnly(),
    escrowPaymentAccount.toWritable(),
    authority.toReadOnly(),
    auctioneerAuthority.toSigner(),
    auctionHouse.toReadOnly(),
    auctionHouseFeeAccount.toWritable(),
    buyerTradeState.toWritable(),
    ahAuctioneerPda.toReadOnly(),
    tokenProgram.toReadOnly(),
    systemProgram.toReadOnly(),
    rent.toReadOnly()
  ], programId: MetaplexAuctionHouseProgramConst.programId, layout: layout);
}