pub trait FullExchange: Exchange + WsExchange { }Expand description
Combined trait for exchanges that support both REST and WebSocket
This trait is automatically implemented for any type that implements
both Exchange and WsExchange.
§Example
use ccxt_core::ws_exchange::FullExchange;
async fn use_full_exchange(exchange: &dyn FullExchange) {
// Use REST API
let ticker = exchange.fetch_ticker("BTC/USDT").await.unwrap();
// Use WebSocket API
exchange.ws_connect().await.unwrap();
let stream = exchange.watch_ticker("BTC/USDT").await.unwrap();
}