pub struct MarketWithdrawBuilder { /* private fields */ }Expand description
Instruction builder for MarketWithdraw.
§Accounts:
[signer]authority[]market[]mint_a[]mint_b[writable]authority_a[writable]authority_b[writable]market_a[writable]market_b[]token_program_a[]token_program_b[]memo_program
Implementations§
Source§impl MarketWithdrawBuilder
impl MarketWithdrawBuilder
pub fn new() -> Self
The authority
The authority’s token account for token a
The authority’s token account for token b
Sourcepub fn market_a(&mut self, market_a: Address) -> &mut Self
pub fn market_a(&mut self, market_a: Address) -> &mut Self
The market token account for token a
Sourcepub fn market_b(&mut self, market_b: Address) -> &mut Self
pub fn market_b(&mut self, market_b: Address) -> &mut Self
The market token account for token b
Sourcepub fn token_program_a(&mut self, token_program_a: Address) -> &mut Self
pub fn token_program_a(&mut self, token_program_a: Address) -> &mut Self
The token program for token a
Sourcepub fn token_program_b(&mut self, token_program_b: Address) -> &mut Self
pub fn token_program_b(&mut self, token_program_b: Address) -> &mut Self
The token program for token b
Sourcepub fn memo_program(&mut self, memo_program: Address) -> &mut Self
pub fn memo_program(&mut self, memo_program: Address) -> &mut Self
The memo program
pub fn amount_a(&mut self, amount_a: u64) -> &mut Self
pub fn amount_b(&mut self, amount_b: u64) -> &mut Self
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 MarketWithdrawBuilder
impl Clone for MarketWithdrawBuilder
Source§fn clone(&self) -> MarketWithdrawBuilder
fn clone(&self) -> MarketWithdrawBuilder
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 MarketWithdrawBuilder
impl Debug for MarketWithdrawBuilder
Source§impl Default for MarketWithdrawBuilder
impl Default for MarketWithdrawBuilder
Source§fn default() -> MarketWithdrawBuilder
fn default() -> MarketWithdrawBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for MarketWithdrawBuilder
impl RefUnwindSafe for MarketWithdrawBuilder
impl Send for MarketWithdrawBuilder
impl Sync for MarketWithdrawBuilder
impl Unpin for MarketWithdrawBuilder
impl UnsafeUnpin for MarketWithdrawBuilder
impl UnwindSafe for MarketWithdrawBuilder
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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