pub struct ReplaceAttachedParams { /* private fields */ }Expand description
Attached order parameters for replace order
Implementations§
Source§impl ReplaceAttachedParams
impl ReplaceAttachedParams
Sourcepub fn new(attached_order_type: AttachedOrderType) -> Self
pub fn new(attached_order_type: AttachedOrderType) -> Self
Create new ReplaceAttachedParams
Sourcepub fn profit_taker_price(self, v: Decimal) -> Self
pub fn profit_taker_price(self, v: Decimal) -> Self
Set the take-profit trigger price
Sourcepub fn stop_loss_price(self, v: Decimal) -> Self
pub fn stop_loss_price(self, v: Decimal) -> Self
Set the stop-loss trigger price
Sourcepub fn time_in_force(self, v: TimeInForceType) -> Self
pub fn time_in_force(self, v: TimeInForceType) -> Self
Set the time in force type
Sourcepub fn expire_time(self, v: i64) -> Self
pub fn expire_time(self, v: i64) -> Self
Set the expiry time (unix timestamp seconds)
Sourcepub fn activate_order_type(self, v: OrderType) -> Self
pub fn activate_order_type(self, v: OrderType) -> Self
Set the order type to submit after trigger
Sourcepub fn profit_taker_submit_price(self, v: Decimal) -> Self
pub fn profit_taker_submit_price(self, v: Decimal) -> Self
Set the take-profit limit price
Sourcepub fn stop_loss_submit_price(self, v: Decimal) -> Self
pub fn stop_loss_submit_price(self, v: Decimal) -> Self
Set the stop-loss limit price
Sourcepub fn activate_rth(self, v: OutsideRTH) -> Self
pub fn activate_rth(self, v: OutsideRTH) -> Self
Set the RTH setting for the activated order
Sourcepub fn profit_taker_id(self, v: i64) -> Self
pub fn profit_taker_id(self, v: i64) -> Self
Set the take-profit order ID (for modifying existing attached order)
Sourcepub fn stop_loss_id(self, v: i64) -> Self
pub fn stop_loss_id(self, v: i64) -> Self
Set the stop-loss order ID (for modifying existing attached order)
Sourcepub fn cancel_all_attached(self) -> Self
pub fn cancel_all_attached(self) -> Self
Cancel all attached orders
Sourcepub fn market_price(self, v: Decimal) -> Self
pub fn market_price(self, v: Decimal) -> Self
Set the market price
Trait Implementations§
Source§impl Clone for ReplaceAttachedParams
impl Clone for ReplaceAttachedParams
Source§fn clone(&self) -> ReplaceAttachedParams
fn clone(&self) -> ReplaceAttachedParams
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 ReplaceAttachedParams
impl Debug for ReplaceAttachedParams
Auto Trait Implementations§
impl Freeze for ReplaceAttachedParams
impl RefUnwindSafe for ReplaceAttachedParams
impl Send for ReplaceAttachedParams
impl Sync for ReplaceAttachedParams
impl Unpin for ReplaceAttachedParams
impl UnsafeUnpin for ReplaceAttachedParams
impl UnwindSafe for ReplaceAttachedParams
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