pub struct CoinbaseFeeder { /* private fields */ }Expand description
Coinbase market data feeder
Implementations§
Trait Implementations§
Source§impl Debug for CoinbaseFeeder
impl Debug for CoinbaseFeeder
Source§impl Default for CoinbaseFeeder
impl Default for CoinbaseFeeder
Source§impl Feeder for CoinbaseFeeder
impl Feeder for CoinbaseFeeder
Source§type DepthMessage = Level2Update
type DepthMessage = Level2Update
Raw message type from the exchange for depth/orderbook
Source§type TradeMessage = TradeMessage
type TradeMessage = TradeMessage
Raw message type from the exchange for trades
Source§fn start_feed_depth<'life0, 'async_trait>(
&'life0 self,
instrument_id: InstrumentId,
depth_rx: Receiver<Self::DepthMessage>,
_options: Option<FeederOptions>,
) -> Pin<Box<dyn Future<Output = Result<Receiver<OrderBookSnapshot>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn start_feed_depth<'life0, 'async_trait>(
&'life0 self,
instrument_id: InstrumentId,
depth_rx: Receiver<Self::DepthMessage>,
_options: Option<FeederOptions>,
) -> Pin<Box<dyn Future<Output = Result<Receiver<OrderBookSnapshot>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Start processing and normalizing orderbook depth data
Processes raw depth messages into standardized order book depth format
Source§fn stop_feed_depth<'life0, 'life1, 'async_trait>(
&'life0 self,
instrument_id: &'life1 InstrumentId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn stop_feed_depth<'life0, 'life1, 'async_trait>(
&'life0 self,
instrument_id: &'life1 InstrumentId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Stop processing orderbook depth data for a specific instrument
Source§fn start_feed_trades<'life0, 'async_trait>(
&'life0 self,
instrument_id: InstrumentId,
trade_rx: Receiver<Self::TradeMessage>,
_options: Option<FeederOptions>,
) -> Pin<Box<dyn Future<Output = Result<Receiver<MarketTrade>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn start_feed_trades<'life0, 'async_trait>(
&'life0 self,
instrument_id: InstrumentId,
trade_rx: Receiver<Self::TradeMessage>,
_options: Option<FeederOptions>,
) -> Pin<Box<dyn Future<Output = Result<Receiver<MarketTrade>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Start processing and normalizing trade data
Processes raw trade messages into standardized trade format
Source§fn stop_feed_trades<'life0, 'life1, 'async_trait>(
&'life0 self,
instrument_id: &'life1 InstrumentId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn stop_feed_trades<'life0, 'life1, 'async_trait>(
&'life0 self,
instrument_id: &'life1 InstrumentId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Stop processing trade data for a specific instrument
Source§fn start_feed_bars<'life0, 'async_trait>(
&'life0 self,
instrument_id: InstrumentId,
bar_type: BarType,
trade_rx: Receiver<MarketTrade>,
_options: Option<FeederOptions>,
) -> Pin<Box<dyn Future<Output = Result<Receiver<Bar>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn start_feed_bars<'life0, 'async_trait>(
&'life0 self,
instrument_id: InstrumentId,
bar_type: BarType,
trade_rx: Receiver<MarketTrade>,
_options: Option<FeederOptions>,
) -> Pin<Box<dyn Future<Output = Result<Receiver<Bar>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Start generating bars from trade data
Aggregates trade data into OHLCV bars of the specified type
Source§fn stop_feed_bars<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
instrument_id: &'life1 InstrumentId,
bar_type: &'life2 BarType,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn stop_feed_bars<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
instrument_id: &'life1 InstrumentId,
bar_type: &'life2 BarType,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Stop generating bars for a specific instrument and bar type
Get a real-time shared orderbook for a specific instrument
Returns a thread-safe shared orderbook that’s kept up-to-date
Source§fn get_bar_cache<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_instrument_id: &'life1 InstrumentId,
_bar_type: &'life2 BarType,
max_bars: usize,
) -> Pin<Box<dyn Future<Output = Result<Arc<RwLock<BarCache>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_bar_cache<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_instrument_id: &'life1 InstrumentId,
_bar_type: &'life2 BarType,
max_bars: usize,
) -> Pin<Box<dyn Future<Output = Result<Arc<RwLock<BarCache>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Get a bar cache for a specific instrument and bar type
Returns a bar cache with recent bar data
Auto Trait Implementations§
impl Freeze for CoinbaseFeeder
impl !RefUnwindSafe for CoinbaseFeeder
impl Send for CoinbaseFeeder
impl Sync for CoinbaseFeeder
impl Unpin for CoinbaseFeeder
impl !UnwindSafe for CoinbaseFeeder
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