Struct lfest::Exchange [−][src]
pub struct Exchange { /* fields omitted */ }
Expand description
The main leveraged futures exchange for simulated trading
Implementations
Create a new Exchange with the desired config and whether to use candles as infomation source
Return a mutable reference to Account
Update the exchange state with a new trade.
Parameters
bid: bid price ask: ask price timestamp: timestamp usually in milliseconds
Returns
executed orders true if position has been liquidated
Submit a new order to the exchange. Returns the order with timestamp and id filled in or OrderError
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Exchange
impl UnwindSafe for Exchange
Blanket Implementations
Mutably borrows from an owned value. Read more