MetaplexTokenMetaDataProgram.migrate constructor
MetaplexTokenMetaDataProgram.migrate({
- required SolAddress metadata,
- required SolAddress edition,
- required SolAddress token,
- required SolAddress tokenOwner,
- required SolAddress mint,
- required SolAddress payer,
- required SolAddress authority,
- required SolAddress collectionMetadata,
- required SolAddress delegateRecord,
- required SolAddress tokenRecord,
- SolAddress systemProgram = SystemProgramConst.programId,
- required SolAddress sysvarInstructions,
- required SolAddress splTokenProgram,
- SolAddress? authorizationRulesProgram,
- SolAddress? authorizationRules,
Implementation
factory MetaplexTokenMetaDataProgram.migrate({
required SolAddress metadata,
required SolAddress edition,
required SolAddress token,
required SolAddress tokenOwner,
required SolAddress mint,
required SolAddress payer,
required SolAddress authority,
required SolAddress collectionMetadata,
required SolAddress delegateRecord,
required SolAddress tokenRecord,
SolAddress systemProgram = SystemProgramConst.programId,
required SolAddress sysvarInstructions,
required SolAddress splTokenProgram,
SolAddress? authorizationRulesProgram,
SolAddress? authorizationRules,
}) {
return MetaplexTokenMetaDataProgram(
keys: [
metadata.toWritable(),
edition.toWritable(),
token.toWritable(),
tokenOwner.toReadOnly(),
mint.toReadOnly(),
payer.toSignerAndWritable(),
authority.toSigner(),
collectionMetadata.toReadOnly(),
delegateRecord.toReadOnly(),
tokenRecord.toWritable(),
systemProgram.toReadOnly(),
sysvarInstructions.toReadOnly(),
splTokenProgram.toReadOnly(),
authorizationRulesProgram?.toReadOnly() ??
MetaplexTokenMetaDataProgramConst.programId.toReadOnly(),
authorizationRules?.toReadOnly() ??
MetaplexTokenMetaDataProgramConst.programId.toReadOnly(),
],
programId: MetaplexTokenMetaDataProgramConst.programId,
layout: const MetaplexTokenMetaDataMigrateLayout());
}