pub struct CreatePurchaseOrderCpiBuilder<'a, 'b> { /* private fields */ }Expand description
Instruction builder for CreatePurchaseOrder via CPI.
§Accounts:
[writable, signer]user_wallet[]bond_account[]issuance_account[writable]payment_account[writable]payment_token_account[writable]user_payment_token_account[writable]user_nft_token_account[writable, signer]nft_mint_account[writable]nft_metadata_account[writable]nft_master_edition_account[writable]purchase_order_vault_account[]nft_collection_mint[writable]nft_collection_metadata_account[]nft_collection_master_edition_account[]payment_mint_account[]payment_feed_account[]payment_base_price_feed_account[]config_account[]associated_token_program[]token2022_program[]token_program[]system_program[]metadata_program[]sysvar_instructions[optional]payment_quote_price_feed_account
Implementations§
Source§impl<'a, 'b> CreatePurchaseOrderCpiBuilder<'a, 'b>
impl<'a, 'b> CreatePurchaseOrderCpiBuilder<'a, 'b>
pub fn new(program: &'b AccountInfo<'a>) -> Self
pub fn user_wallet(&mut self, user_wallet: &'b AccountInfo<'a>) -> &mut Self
pub fn bond_account(&mut self, bond_account: &'b AccountInfo<'a>) -> &mut Self
pub fn issuance_account( &mut self, issuance_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn payment_account( &mut self, payment_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn payment_token_account( &mut self, payment_token_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn user_payment_token_account( &mut self, user_payment_token_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn user_nft_token_account( &mut self, user_nft_token_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn nft_mint_account( &mut self, nft_mint_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn nft_metadata_account( &mut self, nft_metadata_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn nft_master_edition_account( &mut self, nft_master_edition_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn purchase_order_vault_account( &mut self, purchase_order_vault_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn nft_collection_mint( &mut self, nft_collection_mint: &'b AccountInfo<'a>, ) -> &mut Self
pub fn nft_collection_metadata_account( &mut self, nft_collection_metadata_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn nft_collection_master_edition_account( &mut self, nft_collection_master_edition_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn payment_mint_account( &mut self, payment_mint_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn payment_feed_account( &mut self, payment_feed_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn payment_base_price_feed_account( &mut self, payment_base_price_feed_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn config_account( &mut self, config_account: &'b AccountInfo<'a>, ) -> &mut Self
pub fn associated_token_program( &mut self, associated_token_program: &'b AccountInfo<'a>, ) -> &mut Self
pub fn token2022_program( &mut self, token2022_program: &'b AccountInfo<'a>, ) -> &mut Self
pub fn token_program(&mut self, token_program: &'b AccountInfo<'a>) -> &mut Self
pub fn system_program( &mut self, system_program: &'b AccountInfo<'a>, ) -> &mut Self
pub fn metadata_program( &mut self, metadata_program: &'b AccountInfo<'a>, ) -> &mut Self
pub fn sysvar_instructions( &mut self, sysvar_instructions: &'b AccountInfo<'a>, ) -> &mut Self
Sourcepub fn payment_quote_price_feed_account(
&mut self,
payment_quote_price_feed_account: Option<&'b AccountInfo<'a>>,
) -> &mut Self
pub fn payment_quote_price_feed_account( &mut self, payment_quote_price_feed_account: Option<&'b AccountInfo<'a>>, ) -> &mut Self
[optional account]
pub fn amount(&mut self, amount: u64) -> &mut Self
Sourcepub fn add_remaining_account(
&mut self,
account: &'b AccountInfo<'a>,
is_writable: bool,
is_signer: bool,
) -> &mut Self
pub fn add_remaining_account( &mut self, account: &'b AccountInfo<'a>, is_writable: bool, is_signer: bool, ) -> &mut Self
Add an additional account to the instruction.
Sourcepub fn add_remaining_accounts(
&mut self,
accounts: &[(&'b AccountInfo<'a>, bool, bool)],
) -> &mut Self
pub fn add_remaining_accounts( &mut self, accounts: &[(&'b AccountInfo<'a>, bool, bool)], ) -> &mut Self
Add additional accounts to the instruction.
Each account is represented by a tuple of the AccountInfo, a bool indicating whether the account is writable or not,
and a bool indicating whether the account is a signer or not.
pub fn invoke(&self) -> ProgramResult
pub fn invoke_signed(&self, signers_seeds: &[&[&[u8]]]) -> ProgramResult
Auto Trait Implementations§
impl<'a, 'b> Freeze for CreatePurchaseOrderCpiBuilder<'a, 'b>
impl<'a, 'b> !RefUnwindSafe for CreatePurchaseOrderCpiBuilder<'a, 'b>
impl<'a, 'b> !Send for CreatePurchaseOrderCpiBuilder<'a, 'b>
impl<'a, 'b> !Sync for CreatePurchaseOrderCpiBuilder<'a, 'b>
impl<'a, 'b> Unpin for CreatePurchaseOrderCpiBuilder<'a, 'b>
impl<'a, 'b> !UnwindSafe for CreatePurchaseOrderCpiBuilder<'a, 'b>
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
Mutably borrows from an owned value. Read more
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>
Converts
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>
Converts
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