pub enum OrderItem {
Order(Order),
Modify(Modify),
Cancel(Cancel),
CancelAll(CancelAll),
Stop(Stop),
TakeProfit(TakeProfit),
RangeOco(RangeOco),
TriggerBasket(TriggerBasket),
OnFill(OnFill),
TrailingStop(TrailingStop),
}Expand description
An item in the orders array
Variants§
Order(Order)
Place a new order
Modify(Modify)
Modify an existing order size
Cancel(Cancel)
Cancel a specific order
CancelAll(CancelAll)
Cancel all orders
Stop(Stop)
Stop-loss conditional order
TakeProfit(TakeProfit)
Take-profit conditional order
RangeOco(RangeOco)
Range / OCO collar order
TriggerBasket(TriggerBasket)
Trigger basket: fires nested actions when price crosses threshold
OnFill(OnFill)
On-fill consequent: inline trigger plus one-shot follow-up actions
TrailingStop(TrailingStop)
Trailing stop: protective stop that follows price by a fixed bps distance
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for OrderItem
impl<'de> Deserialize<'de> for OrderItem
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 From<TrailingStop> for OrderItem
impl From<TrailingStop> for OrderItem
Source§fn from(trl: TrailingStop) -> Self
fn from(trl: TrailingStop) -> Self
Converts to this type from the input type.
Source§impl From<TriggerBasket> for OrderItem
impl From<TriggerBasket> for OrderItem
Source§fn from(trig: TriggerBasket) -> Self
fn from(trig: TriggerBasket) -> Self
Converts to this type from the input type.
impl StructuralPartialEq for OrderItem
Auto Trait Implementations§
impl Freeze for OrderItem
impl RefUnwindSafe for OrderItem
impl Send for OrderItem
impl Sync for OrderItem
impl Unpin for OrderItem
impl UnsafeUnpin for OrderItem
impl UnwindSafe for OrderItem
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