pub struct TakeProfit {
pub symbol: String,
pub is_buy: bool,
pub size: f64,
pub trigger_price: f64,
pub limit_price: f64,
pub iso: bool,
}Expand description
Take-profit order: triggers when price crosses threshold
Fields§
§symbol: String§is_buy: booltrue = buy/long side, false = sell/short side
size: f64§trigger_price: f64§limit_price: f64Limit price; NaN means market-style fill
iso: boolIsolated-margin flag
Trait Implementations§
Source§impl Clone for TakeProfit
impl Clone for TakeProfit
Source§fn clone(&self) -> TakeProfit
fn clone(&self) -> TakeProfit
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 TakeProfit
impl Debug for TakeProfit
Source§impl<'de> Deserialize<'de> for TakeProfit
impl<'de> Deserialize<'de> for TakeProfit
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
Source§impl From<TakeProfit> for OrderItem
impl From<TakeProfit> for OrderItem
Source§fn from(tp: TakeProfit) -> Self
fn from(tp: TakeProfit) -> Self
Converts to this type from the input type.
Source§impl PartialEq for TakeProfit
impl PartialEq for TakeProfit
Source§impl Serialize for TakeProfit
impl Serialize for TakeProfit
impl StructuralPartialEq for TakeProfit
Auto Trait Implementations§
impl Freeze for TakeProfit
impl RefUnwindSafe for TakeProfit
impl Send for TakeProfit
impl Sync for TakeProfit
impl Unpin for TakeProfit
impl UnsafeUnpin for TakeProfit
impl UnwindSafe for TakeProfit
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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