Struct MockDataClient

Source
pub struct MockDataClient {
    pub client_id: ClientId,
    pub venue: Venue,
    /* private fields */
}

Fields§

§client_id: ClientId§venue: Venue

Implementations§

Source§

impl MockDataClient

Source

pub const fn new( cache: Rc<RefCell<Cache>>, client_id: ClientId, venue: Venue, ) -> Self

Creates a new MockDataClient instance.

Trait Implementations§

Source§

impl DataClient for MockDataClient

Source§

fn client_id(&self) -> ClientId

Source§

fn venue(&self) -> Option<Venue>

Source§

fn start(&self)

Source§

fn stop(&self)

Source§

fn reset(&self)

Source§

fn dispose(&self)

Source§

fn is_connected(&self) -> bool

Source§

fn is_disconnected(&self) -> bool

Source§

fn subscribe(&mut self, _cmd: SubscribeData) -> Result<()>

Source§

fn subscribe_instruments(&mut self, _cmd: SubscribeInstruments) -> Result<()>

Source§

fn subscribe_instrument(&mut self, _cmd: SubscribeInstrument) -> Result<()>

Source§

fn subscribe_book_deltas(&mut self, _cmd: SubscribeBookDeltas) -> Result<()>

Source§

fn subscribe_book_depth10(&mut self, _cmd: SubscribeBookDepth10) -> Result<()>

Source§

fn subscribe_book_snapshots( &mut self, _cmd: SubscribeBookSnapshots, ) -> Result<()>

Source§

fn subscribe_quotes(&mut self, _cmd: SubscribeQuotes) -> Result<()>

Source§

fn subscribe_trades(&mut self, _cmd: SubscribeTrades) -> Result<()>

Source§

fn subscribe_bars(&mut self, _cmd: SubscribeBars) -> Result<()>

Source§

fn subscribe_mark_prices(&mut self, _cmd: SubscribeMarkPrices) -> Result<()>

Source§

fn subscribe_index_prices(&mut self, _cmd: SubscribeIndexPrices) -> Result<()>

Source§

fn subscribe_instrument_status( &mut self, _cmd: SubscribeInstrumentStatus, ) -> Result<()>

Source§

fn subscribe_instrument_close( &mut self, _cmd: SubscribeInstrumentClose, ) -> Result<()>

Source§

fn unsubscribe(&mut self, _cmd: UnsubscribeData) -> Result<()>

Source§

fn unsubscribe_instruments( &mut self, _cmd: UnsubscribeInstruments, ) -> Result<()>

Source§

fn unsubscribe_instrument(&mut self, _cmd: UnsubscribeInstrument) -> Result<()>

Source§

fn unsubscribe_book_deltas(&mut self, _cmd: UnsubscribeBookDeltas) -> Result<()>

Source§

fn unsubscribe_book_depth10( &mut self, _cmd: UnsubscribeBookDepth10, ) -> Result<()>

Source§

fn unsubscribe_book_snapshots( &mut self, _cmd: UnsubscribeBookSnapshots, ) -> Result<()>

Source§

fn unsubscribe_quotes(&mut self, _cmd: UnsubscribeQuotes) -> Result<()>

Source§

fn unsubscribe_trades(&mut self, _cmd: UnsubscribeTrades) -> Result<()>

Source§

fn unsubscribe_bars(&mut self, _cmd: UnsubscribeBars) -> Result<()>

Source§

fn unsubscribe_mark_prices(&mut self, _cmd: UnsubscribeMarkPrices) -> Result<()>

Source§

fn unsubscribe_index_prices( &mut self, _cmd: UnsubscribeIndexPrices, ) -> Result<()>

Source§

fn unsubscribe_instrument_status( &mut self, _cmd: UnsubscribeInstrumentStatus, ) -> Result<()>

Source§

fn unsubscribe_instrument_close( &mut self, _cmd: UnsubscribeInstrumentClose, ) -> Result<()>

Source§

fn request_data(&self, request: RequestData) -> Result<()>

Source§

fn request_instruments(&self, request: RequestInstruments) -> Result<()>

Requests instruments data from the data provider.
Source§

fn request_instrument(&self, request: RequestInstrument) -> Result<()>

Requests instrument data from the data provider.
Source§

fn request_book_snapshot(&self, request: RequestBookSnapshot) -> Result<()>

Requests a book snapshot from the data provider.
Source§

fn request_quotes(&self, request: RequestQuotes) -> Result<()>

Requests quotes data from the data provider.
Source§

fn request_trades(&self, request: RequestTrades) -> Result<()>

Requests trades data from the data provider.
Source§

fn request_bars(&self, request: RequestBars) -> Result<()>

Requests bars data from the data provider.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more