pub struct OrderInput {
pub instrument: InstrumentId,
pub market_index: MarketIndex,
pub client_id: ClientOrderId,
pub side: OrderSide,
pub price: Price,
pub qty: Qty,
pub tif: TimeInForce,
pub post_only: bool,
pub reduce_only: bool,
}Expand description
Input parameters for placing an order.
Fields§
§instrument: InstrumentIdCanonical instrument ID used by the engine.
market_index: MarketIndexExchange-specific market index or encoded asset ID.
client_id: ClientOrderIdClient order ID generated by the bot.
side: OrderSideBuy or sell side.
price: PriceLimit price.
qty: QtyOrder quantity.
tif: TimeInForceTime-in-force instruction.
post_only: boolWhether the exchange must reject the order if it would take liquidity.
reduce_only: boolWhether the order may only reduce an existing position.
Trait Implementations§
Source§impl Clone for OrderInput
impl Clone for OrderInput
Source§fn clone(&self) -> OrderInput
fn clone(&self) -> OrderInput
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 OrderInput
impl Debug for OrderInput
Source§impl<'de> Deserialize<'de> for OrderInput
impl<'de> Deserialize<'de> for OrderInput
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 OrderInput
impl RefUnwindSafe for OrderInput
impl Send for OrderInput
impl Sync for OrderInput
impl Unpin for OrderInput
impl UnsafeUnpin for OrderInput
impl UnwindSafe for OrderInput
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