pub struct OrderInfo {
pub market_index: i16,
pub client_order_index: i64,
pub base_amount: i64,
pub price: u32,
pub is_ask: bool,
pub order_type: u8,
pub time_in_force: u8,
pub reduce_only: bool,
pub trigger_price: u32,
pub order_expiry: i64,
}Expand description
Common per-order body fields shared by CreateOrderTxInfo and the
not-yet-implemented CreateGroupedOrders variant.
Fields§
§market_index: i16Market identifier. Spot markets use 2048..=4094, perps 0..=254.
client_order_index: i64Caller-supplied unique-per-account order index.
base_amount: i64Order size in base-asset ticks.
price: u32Limit / trigger price in quote-asset ticks.
is_ask: booltrue for a sell, false for a buy. Wire-encoded as 1 or 0.
order_type: u8Order type discriminant; see LighterOrderType for the mapping.
time_in_force: u8Time-in-force discriminant; see LighterTimeInForce for the mapping.
reduce_only: booltrue for a reduce-only order. Wire-encoded as 1 or 0.
trigger_price: u32Trigger price for stop / take-profit variants; 0 when unused.
order_expiry: i64Order expiry in milliseconds; 0 for IOC, -1 for the venue default.
Trait Implementations§
impl Copy for OrderInfo
impl Eq for OrderInfo
impl StructuralPartialEq for OrderInfo
Auto Trait Implementations§
impl Freeze for OrderInfo
impl RefUnwindSafe for OrderInfo
impl Send for OrderInfo
impl Sync for OrderInfo
impl Unpin for OrderInfo
impl UnsafeUnpin for OrderInfo
impl UnwindSafe for OrderInfo
Blanket Implementations§
impl<T> Allocation for T
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§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