pub struct BinanceWebsocket { /* private fields */ }Expand description
This struct is used for websocket communications with openlimits-binance openlimits-exchange
Trait Implementations§
Source§impl ExchangeStream for BinanceWebsocket
impl ExchangeStream for BinanceWebsocket
type InitParams = BinanceParameters
type Subscription = BinanceSubscription
type Response = BinanceWebsocketMessage
fn new<'async_trait>(
parameters: Self::InitParams,
) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>where
Self: 'async_trait,
fn disconnect<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create_stream_specific<'life0, 'async_trait>(
&'life0 self,
subscriptions: Subscriptions<Self::Subscription>,
) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, Result<Self::Response>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn subscribe<'life0, 'async_trait, S, F>(
&'life0 self,
subscription: S,
callback: F,
) -> Pin<Box<dyn Future<Output = Result<CallbackHandle, OpenLimitsError>> + Send + 'async_trait>>where
'life0: 'async_trait,
S: 'async_trait + Into<Self::Subscription> + Sync + Send + Clone,
F: 'async_trait + FnMut(&Result<WebSocketResponse<Self::Response>, OpenLimitsError>) + Send + 'static,
Self: 'async_trait,
fn create_stream<'life0, 'life1, 'async_trait, S>(
&'life0 self,
subscriptions: &'life1 [S],
) -> Pin<Box<dyn Future<Output = Result<Pin<Box<dyn Stream<Item = Result<WebSocketResponse<Self::Response>, OpenLimitsError>> + Send>>, OpenLimitsError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
S: 'async_trait + Into<Self::Subscription> + Clone + Send + Sync,
Self: 'async_trait,
Auto Trait Implementations§
impl !Freeze for BinanceWebsocket
impl RefUnwindSafe for BinanceWebsocket
impl Send for BinanceWebsocket
impl Sync for BinanceWebsocket
impl Unpin for BinanceWebsocket
impl UnsafeUnpin for BinanceWebsocket
impl UnwindSafe for BinanceWebsocket
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