MetaplexAuctioneerProgram.authorize constructor

MetaplexAuctioneerProgram.authorize({
  1. required SolAddress wallet,
  2. required SolAddress auctionHouse,
  3. required SolAddress auctioneerAuthority,
  4. SolAddress systemProgram = SystemProgramConst.programId,
})

Authorize the Auctioneer to manage an Auction House.

Implementation

factory MetaplexAuctioneerProgram.authorize({
  /// User wallet account.
  required SolAddress wallet,

  /// Auction House instance PDA account.
  required SolAddress auctionHouse,

  /// The auctioneer program PDA running this auction.
  required SolAddress auctioneerAuthority,
  SolAddress systemProgram = SystemProgramConst.programId,
}) {
  return MetaplexAuctioneerProgram(
      keys: [
        wallet.toSignerAndWritable(),
        auctionHouse.toReadOnly(),
        auctioneerAuthority.toWritable(),
        systemProgram.toReadOnly(),
      ],
      programId: MetaplexAuctioneerProgramConst.programId,
      layout: MetaplexAuctioneerAuthorizeLayout());
}