Skip to main content

QuoteProvider

Trait QuoteProvider 

Source
pub trait QuoteProvider: Send + Sync {
    // Required methods
    fn get_quote(&self, symbol: &str) -> Option<SnapshotBookQuote>;
    fn get_quote_with_seq(
        &self,
        symbol: &str,
    ) -> (Option<SnapshotBookQuote>, i64);
    fn book_snapshot_state(&self, symbol: &str) -> BookSnapshotState;
    fn all_quotes(&self) -> HashMap<String, SnapshotBookQuote>;
    fn l2_seq(&self) -> i64;
    fn snapshot(&self) -> QuoteSnapshot;
    fn staleness(&self) -> Duration;
}
Expand description

Read-only interface for accessing orderbook quotes.

Required Methods§

Implementors§