pub struct DecreaseSpotPositionQuoteResult {
pub decrease_percent: u32,
pub collateral_token: u8,
pub position_token: u8,
pub collateral: u64,
pub borrow: u64,
pub decrease_acceptable_swap_amount: u64,
pub increase_min_swap_output_amount: u64,
pub estimated_amount: u64,
pub protocol_fee_a: u64,
pub protocol_fee_b: u64,
pub price_impact: f64,
}Fields§
§decrease_percent: u32Position decrease percentage
collateral_token: u8Collateral token of the new position
position_token: u8Token of the new position
collateral: u64Required additional collateral amount
borrow: u64Required amount to borrow
decrease_acceptable_swap_amount: u64The maximum acceptable swap input amount for position decrease according to the provided slippage (if collateral_token == position_token) OR the minimum swap output amount (if collateral_token != position_token).
increase_min_swap_output_amount: u64The minimum swap output amount for position increase according to the provided slippage.
estimated_amount: u64Estimated total amount of the new position
protocol_fee_a: u64Protocol fee in token A
protocol_fee_b: u64Protocol fee in token B
price_impact: f64Price impact in percents
Auto Trait Implementations§
impl Freeze for DecreaseSpotPositionQuoteResult
impl RefUnwindSafe for DecreaseSpotPositionQuoteResult
impl Send for DecreaseSpotPositionQuoteResult
impl Sync for DecreaseSpotPositionQuoteResult
impl Unpin for DecreaseSpotPositionQuoteResult
impl UnwindSafe for DecreaseSpotPositionQuoteResult
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