pub struct LiveDetails {
pub pnl: f64,
pub funding_payment: f64,
pub effective_margin: f64,
pub is_liquidatable: bool,
}Expand description
Real-time position metrics, typically from a quoteClosePosition call.
All USDC values are human-readable (e.g. 12.50 not 12_500_000).
Fields§
§pnl: f64Unrealized PnL in USDC.
funding_payment: f64Accumulated funding payment in USDC (positive = received).
effective_margin: f64Current effective margin in USDC.
is_liquidatable: boolWhether this position would be liquidated at the current price.
Trait Implementations§
Source§impl Clone for LiveDetails
impl Clone for LiveDetails
Source§fn clone(&self) -> LiveDetails
fn clone(&self) -> LiveDetails
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 LiveDetails
impl Debug for LiveDetails
Source§impl PartialEq for LiveDetails
impl PartialEq for LiveDetails
impl Copy for LiveDetails
impl StructuralPartialEq for LiveDetails
Auto Trait Implementations§
impl Freeze for LiveDetails
impl RefUnwindSafe for LiveDetails
impl Send for LiveDetails
impl Sync for LiveDetails
impl Unpin for LiveDetails
impl UnsafeUnpin for LiveDetails
impl UnwindSafe for LiveDetails
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> 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