pub struct DepositNftT22Builder { /* private fields */ }Expand description
Instruction builder for DepositNftT22.
§Accounts:
[writable, signer]owner[writable]pool[]whitelist[optional]mint_proof[]mint[writable]nft_receipt[writable]owner_ta[writable]pool_ta[optional]token_program (default toTokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb)[optional]associated_token_program (default toATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL)[optional]system_program (default to11111111111111111111111111111111)
Implementations§
Source§impl DepositNftT22Builder
impl DepositNftT22Builder
pub fn new() -> Self
Sourcepub fn pool(&mut self, pool: Pubkey) -> &mut Self
pub fn pool(&mut self, pool: Pubkey) -> &mut Self
The pool the NFT is being transferred to/from.
Sourcepub fn whitelist(&mut self, whitelist: Pubkey) -> &mut Self
pub fn whitelist(&mut self, whitelist: Pubkey) -> &mut Self
The whitelist that gatekeeps which NFTs can be deposited into the pool. Must match the whitelist stored in the pool state.
Sourcepub fn mint_proof(&mut self, mint_proof: Option<Pubkey>) -> &mut Self
pub fn mint_proof(&mut self, mint_proof: Option<Pubkey>) -> &mut Self
[optional account]
Optional account which must be passed in if the NFT must be verified against a
merkle proof condition in the whitelist.
Sourcepub fn nft_receipt(&mut self, nft_receipt: Pubkey) -> &mut Self
pub fn nft_receipt(&mut self, nft_receipt: Pubkey) -> &mut Self
The NFT deposit receipt, which ties an NFT to the pool it was deposited to.
Sourcepub fn owner_ta(&mut self, owner_ta: Pubkey) -> &mut Self
pub fn owner_ta(&mut self, owner_ta: Pubkey) -> &mut Self
The TA of the owner, where the NFT will be transferred from.
Sourcepub fn pool_ta(&mut self, pool_ta: Pubkey) -> &mut Self
pub fn pool_ta(&mut self, pool_ta: Pubkey) -> &mut Self
The TA of the pool, where the NFT will be escrowed.
Sourcepub fn token_program(&mut self, token_program: Pubkey) -> &mut Self
pub fn token_program(&mut self, token_program: Pubkey) -> &mut Self
[optional account, default to 'TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb']
The SPL Token program for the Mint and ATAs.
Sourcepub fn associated_token_program(
&mut self,
associated_token_program: Pubkey,
) -> &mut Self
pub fn associated_token_program( &mut self, associated_token_program: Pubkey, ) -> &mut Self
[optional account, default to 'ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL']
The SPL associated token program.
Sourcepub fn system_program(&mut self, system_program: Pubkey) -> &mut Self
pub fn system_program(&mut self, system_program: Pubkey) -> &mut Self
[optional account, default to '11111111111111111111111111111111']
The Solana system program.
Sourcepub fn add_remaining_account(&mut self, account: AccountMeta) -> &mut Self
pub fn add_remaining_account(&mut self, account: AccountMeta) -> &mut Self
Add an additional account to the instruction.
Sourcepub fn add_remaining_accounts(&mut self, accounts: &[AccountMeta]) -> &mut Self
pub fn add_remaining_accounts(&mut self, accounts: &[AccountMeta]) -> &mut Self
Add additional accounts to the instruction.
pub fn instruction(&self) -> Instruction
Trait Implementations§
Source§impl Clone for DepositNftT22Builder
impl Clone for DepositNftT22Builder
Source§fn clone(&self) -> DepositNftT22Builder
fn clone(&self) -> DepositNftT22Builder
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for DepositNftT22Builder
impl Debug for DepositNftT22Builder
Source§impl Default for DepositNftT22Builder
impl Default for DepositNftT22Builder
Source§fn default() -> DepositNftT22Builder
fn default() -> DepositNftT22Builder
Auto Trait Implementations§
impl Freeze for DepositNftT22Builder
impl RefUnwindSafe for DepositNftT22Builder
impl Send for DepositNftT22Builder
impl Sync for DepositNftT22Builder
impl Unpin for DepositNftT22Builder
impl UnwindSafe for DepositNftT22Builder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more