pub struct OrderIntent {
pub side: Side,
pub amount: Amount,
pub price: Price,
pub reduce_only: bool,
pub cloid: Option<Cloid>,
pub take_profit: Option<Exit>,
pub stop_loss: Option<Exit>,
}Expand description
An order to place: a market or limit entry, with its take profit and stop loss when it has them.
Fields§
§side: Side§amount: Amount§price: Price§reduce_only: bool§cloid: Option<Cloid>§take_profit: Option<Exit>§stop_loss: Option<Exit>Implementations§
Source§impl OrderIntent
impl OrderIntent
pub const fn with_cloid(self, cloid: Cloid) -> OrderIntent
Sourcepub const fn take_profit(self, exit: Exit) -> OrderIntent
pub const fn take_profit(self, exit: Exit) -> OrderIntent
Placed with the entry, the other way, once it fills.
Sourcepub const fn stop_loss(self, exit: Exit) -> OrderIntent
pub const fn stop_loss(self, exit: Exit) -> OrderIntent
Placed with the entry, the other way, once it fills.
Source§impl OrderIntent
impl OrderIntent
Source§impl OrderIntent
impl OrderIntent
Trait Implementations§
Source§impl Clone for OrderIntent
impl Clone for OrderIntent
impl Copy for OrderIntent
Source§impl Debug for OrderIntent
impl Debug for OrderIntent
impl Eq for OrderIntent
Source§impl PartialEq for OrderIntent
impl PartialEq for OrderIntent
impl StructuralPartialEq for OrderIntent
Auto Trait Implementations§
impl Freeze for OrderIntent
impl RefUnwindSafe for OrderIntent
impl Send for OrderIntent
impl Sync for OrderIntent
impl Unpin for OrderIntent
impl UnsafeUnpin for OrderIntent
impl UnwindSafe for OrderIntent
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,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.