pub struct MatchingOrders { /* private fields */ }Expand description
Pending order state shared by a simulated venue’s instrument engines.
The venue clones one instance into each instrument engine before processing orders. It drains queued commands before the next input, after its engine calls return:
- Pops a command with
Self::pop_command. - Calls
process_oto_commandon the engine forOtoCommand::instrument_id. - After a
OtoCommand::Releasewithparent_quantity: Some(quantity), callsprocess_oto_resizeon the engine forparent_instrument_id, usingparent_order_idandquantity.
Each engine keeps its own book, pending fills, and fee evaluation.
Implementations§
Source§impl MatchingOrders
impl MatchingOrders
Sourcepub fn pop_command(&self) -> Option<OtoCommand>
pub fn pop_command(&self) -> Option<OtoCommand>
Removes the next command without holding a borrow during matching.
Trait Implementations§
Source§impl Clone for MatchingOrders
impl Clone for MatchingOrders
Source§impl Debug for MatchingOrders
impl Debug for MatchingOrders
Auto Trait Implementations§
impl !RefUnwindSafe for MatchingOrders
impl !Send for MatchingOrders
impl !Sync for MatchingOrders
impl !UnwindSafe for MatchingOrders
impl Freeze for MatchingOrders
impl Unpin for MatchingOrders
impl UnsafeUnpin for MatchingOrders
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