pub struct TwoHopSwapBuilder { /* private fields */ }
Expand description
Instruction builder for TwoHopSwap
.
§Accounts:
[writable]
fusion_pool_one[writable]
fusion_pool_two[]
token_mint_input[]
token_mint_intermediate[]
token_mint_output[]
token_program_input[]
token_program_intermediate[]
token_program_output[writable]
token_owner_account_input[writable]
token_vault_one_input[writable]
token_vault_one_intermediate[writable]
token_vault_two_intermediate[writable]
token_vault_two_output[writable]
token_owner_account_output[signer]
token_authority[writable]
tick_array_one0[writable]
tick_array_one1[writable]
tick_array_one2[writable]
tick_array_two0[writable]
tick_array_two1[writable]
tick_array_two2[]
memo_program
Implementations§
Source§impl TwoHopSwapBuilder
impl TwoHopSwapBuilder
pub fn new() -> Self
pub fn fusion_pool_one(&mut self, fusion_pool_one: Pubkey) -> &mut Self
pub fn fusion_pool_two(&mut self, fusion_pool_two: Pubkey) -> &mut Self
pub fn token_mint_input(&mut self, token_mint_input: Pubkey) -> &mut Self
pub fn token_mint_intermediate( &mut self, token_mint_intermediate: Pubkey, ) -> &mut Self
pub fn token_mint_output(&mut self, token_mint_output: Pubkey) -> &mut Self
pub fn token_program_input(&mut self, token_program_input: Pubkey) -> &mut Self
pub fn token_program_intermediate( &mut self, token_program_intermediate: Pubkey, ) -> &mut Self
pub fn token_program_output( &mut self, token_program_output: Pubkey, ) -> &mut Self
pub fn token_owner_account_input( &mut self, token_owner_account_input: Pubkey, ) -> &mut Self
pub fn token_vault_one_input( &mut self, token_vault_one_input: Pubkey, ) -> &mut Self
pub fn token_vault_one_intermediate( &mut self, token_vault_one_intermediate: Pubkey, ) -> &mut Self
pub fn token_vault_two_intermediate( &mut self, token_vault_two_intermediate: Pubkey, ) -> &mut Self
pub fn token_vault_two_output( &mut self, token_vault_two_output: Pubkey, ) -> &mut Self
pub fn token_owner_account_output( &mut self, token_owner_account_output: Pubkey, ) -> &mut Self
pub fn tick_array_one0(&mut self, tick_array_one0: Pubkey) -> &mut Self
pub fn tick_array_one1(&mut self, tick_array_one1: Pubkey) -> &mut Self
pub fn tick_array_one2(&mut self, tick_array_one2: Pubkey) -> &mut Self
pub fn tick_array_two0(&mut self, tick_array_two0: Pubkey) -> &mut Self
pub fn tick_array_two1(&mut self, tick_array_two1: Pubkey) -> &mut Self
pub fn tick_array_two2(&mut self, tick_array_two2: Pubkey) -> &mut Self
pub fn memo_program(&mut self, memo_program: Pubkey) -> &mut Self
pub fn amount(&mut self, amount: u64) -> &mut Self
pub fn other_amount_threshold( &mut self, other_amount_threshold: u64, ) -> &mut Self
pub fn amount_specified_is_input( &mut self, amount_specified_is_input: bool, ) -> &mut Self
pub fn a_to_b_one(&mut self, a_to_b_one: bool) -> &mut Self
pub fn a_to_b_two(&mut self, a_to_b_two: bool) -> &mut Self
pub fn sqrt_price_limit_one(&mut self, sqrt_price_limit_one: u128) -> &mut Self
pub fn sqrt_price_limit_two(&mut self, sqrt_price_limit_two: u128) -> &mut Self
Sourcepub fn remaining_accounts_info(
&mut self,
remaining_accounts_info: RemainingAccountsInfo,
) -> &mut Self
pub fn remaining_accounts_info( &mut self, remaining_accounts_info: RemainingAccountsInfo, ) -> &mut Self
[optional argument]
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 TwoHopSwapBuilder
impl Clone for TwoHopSwapBuilder
Source§fn clone(&self) -> TwoHopSwapBuilder
fn clone(&self) -> TwoHopSwapBuilder
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for TwoHopSwapBuilder
impl Debug for TwoHopSwapBuilder
Source§impl Default for TwoHopSwapBuilder
impl Default for TwoHopSwapBuilder
Source§fn default() -> TwoHopSwapBuilder
fn default() -> TwoHopSwapBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for TwoHopSwapBuilder
impl RefUnwindSafe for TwoHopSwapBuilder
impl Send for TwoHopSwapBuilder
impl Sync for TwoHopSwapBuilder
impl Unpin for TwoHopSwapBuilder
impl UnwindSafe for TwoHopSwapBuilder
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