pub enum SwapAmount {
BaseAmount(f64),
QuoteAmount(f64),
BaseAmountString(String),
QuoteAmountString(String),
}
Variants§
BaseAmount(f64)
/ The amount of in_token_address
tokens to swap.
QuoteAmount(f64)
/ The amount of out_token_address
tokens to swap.
BaseAmountString(String)
/ The amount of in_token_address
tokens to swap.
QuoteAmountString(String)
/ The amount of out_token_address
tokens to swap.
Implementations§
Source§impl SwapAmount
impl SwapAmount
Sourcepub fn merge<B>(
field: &mut Option<SwapAmount>,
tag: u32,
wire_type: WireType,
buf: &mut B,
ctx: DecodeContext,
) -> Result<(), DecodeError>where
B: Buf,
pub fn merge<B>(
field: &mut Option<SwapAmount>,
tag: u32,
wire_type: WireType,
buf: &mut B,
ctx: DecodeContext,
) -> Result<(), DecodeError>where
B: Buf,
Decodes an instance of the message from a buffer, and merges it into self.
Sourcepub fn encoded_len(&self) -> usize
pub fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Trait Implementations§
Source§impl Clone for SwapAmount
impl Clone for SwapAmount
Source§fn clone(&self) -> SwapAmount
fn clone(&self) -> SwapAmount
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 SwapAmount
impl Debug for SwapAmount
Source§impl PartialEq for SwapAmount
impl PartialEq for SwapAmount
impl StructuralPartialEq for SwapAmount
Auto Trait Implementations§
impl Freeze for SwapAmount
impl RefUnwindSafe for SwapAmount
impl Send for SwapAmount
impl Sync for SwapAmount
impl Unpin for SwapAmount
impl UnwindSafe for SwapAmount
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