pub struct BybitPosition {Show 32 fields
pub position_idx: BybitPositionIdx,
pub risk_id: i32,
pub risk_limit_value: String,
pub symbol: Ustr,
pub side: BybitPositionSide,
pub size: String,
pub avg_price: String,
pub position_value: String,
pub trade_mode: i32,
pub position_status: String,
pub auto_add_margin: i32,
pub adl_rank_indicator: i32,
pub leverage: String,
pub position_balance: String,
pub mark_price: String,
pub liq_price: String,
pub bust_price: String,
pub position_mm: String,
pub position_im: String,
pub tpsl_mode: String,
pub take_profit: String,
pub stop_loss: String,
pub trailing_stop: String,
pub unrealised_pnl: String,
pub cur_realised_pnl: String,
pub cum_realised_pnl: String,
pub seq: i64,
pub is_reduce_only: bool,
pub mmr_sys_updated_time: String,
pub leverage_sys_updated_time: String,
pub created_time: String,
pub updated_time: String,
}Expand description
Represents a position returned by the Bybit API.
§References
Fields§
§position_idx: BybitPositionIdx§risk_id: i32§risk_limit_value: String§symbol: Ustr§side: BybitPositionSide§size: String§avg_price: String§position_value: String§trade_mode: i32§position_status: String§auto_add_margin: i32§adl_rank_indicator: i32§leverage: String§position_balance: String§mark_price: String§liq_price: String§bust_price: String§position_mm: String§position_im: String§tpsl_mode: String§take_profit: String§stop_loss: String§trailing_stop: String§unrealised_pnl: String§cur_realised_pnl: String§cum_realised_pnl: String§seq: i64§is_reduce_only: bool§mmr_sys_updated_time: String§leverage_sys_updated_time: String§created_time: String§updated_time: StringTrait Implementations§
Source§impl Clone for BybitPosition
impl Clone for BybitPosition
Source§fn clone(&self) -> BybitPosition
fn clone(&self) -> BybitPosition
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 BybitPosition
impl Debug for BybitPosition
Source§impl<'de> Deserialize<'de> for BybitPosition
impl<'de> Deserialize<'de> for BybitPosition
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for BybitPosition
impl RefUnwindSafe for BybitPosition
impl Send for BybitPosition
impl Sync for BybitPosition
impl Unpin for BybitPosition
impl UnwindSafe for BybitPosition
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,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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