pub struct AccountsManager { /* private fields */ }
Implementations§
Source§impl AccountsManager
impl AccountsManager
pub fn new(clock: Rc<RefCell<dyn Clock>>, cache: Rc<RefCell<Cache>>) -> Self
pub fn update_balances( &self, account: AccountAny, instrument: InstrumentAny, fill: OrderFilled, ) -> AccountState
pub fn update_orders( &self, account: &AccountAny, instrument: InstrumentAny, orders_open: Vec<&OrderAny>, ts_event: UnixNanos, ) -> Option<(AccountAny, AccountState)>
pub fn update_positions( &self, account: &MarginAccount, instrument: InstrumentAny, positions: Vec<&Position>, ts_event: UnixNanos, ) -> Option<(MarginAccount, AccountState)>
Auto Trait Implementations§
impl Freeze for AccountsManager
impl !RefUnwindSafe for AccountsManager
impl !Send for AccountsManager
impl !Sync for AccountsManager
impl Unpin for AccountsManager
impl !UnwindSafe for AccountsManager
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
§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