Struct WsProvider

Source
pub struct WsProvider { /* private fields */ }

Implementations§

Source§

impl WsProvider

Source

pub async fn request( &self, operation: Operation, params: impl Serialize, format: Format, deltas: bool, ) -> StreamResponse<Vec<u8>>

Source

pub fn ready(&self) -> bool

Returns true if the WS connection is active, false otherwise

Trait Implementations§

Source§

impl BtcProvider for WsProvider

Source§

fn get_btc_blocks_by_format<'life0, 'async_trait>( &'life0 self, request: GetBtcBlocksRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_btc_txs_by_format<'life0, 'async_trait>( &'life0 self, request: GetBtcTxsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl ChainProvider for WsProvider

Source§

fn get_blocks_by_format<'life0, 'async_trait>( &'life0 self, request: GetBlocksRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_logs_by_format<'life0, 'async_trait>( &'life0 self, request: GetLogsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_txs_by_format<'life0, 'async_trait>( &'life0 self, request: GetTxsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_transfers_by_format<'life0, 'async_trait>( &'life0 self, request: GetTransfersRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl Clone for WsProvider

Source§

fn clone(&self) -> WsProvider

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl CurveProvider for WsProvider

Source§

fn get_tokens_by_format<'life0, 'async_trait>( &'life0 self, request: GetCrvTokenRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_pools_by_format<'life0, 'async_trait>( &'life0 self, request: GetCrvPoolRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_prices_by_format<'life0, 'async_trait>( &'life0 self, request: GetCrvPriceRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl Debug for WsProvider

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Erc20Provider for WsProvider

Source§

fn get_erc20_by_format<'life0, 'async_trait>( &'life0 self, request: GetErc20Request, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_erc20_approval_by_format<'life0, 'async_trait>( &'life0 self, request: GetErc20ApprovalsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_erc20_transfers_by_format<'life0, 'async_trait>( &'life0 self, request: GetErc20TransferssRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl MoveProvider for WsProvider

Source§

fn get_move_logs_by_format<'life0, 'async_trait>( &'life0 self, request: GetMoveLogsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_logs_decoded_by_format<'life0, 'async_trait>( &'life0 self, request: GetMoveLogsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_txs_by_format<'life0, 'async_trait>( &'life0 self, request: GetMoveTxsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_txs_decoded_by_format<'life0, 'async_trait>( &'life0 self, request: GetMoveTxsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_receipts_by_format<'life0, 'async_trait>( &'life0 self, request: GetMoveReceiptsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_receipts_decoded_by_format<'life0, 'async_trait>( &'life0 self, request: GetMoveReceiptsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_modules_by_format<'life0, 'async_trait>( &'life0 self, request: GetMoveReceiptsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_fa_tokens_by_format<'life0, 'async_trait>( &'life0 self, request: GetTokensRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_coins_by_format<'life0, 'async_trait>( &'life0 self, request: GetTokensRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_interest_v1_pools_by_format<'life0, 'async_trait>( &'life0 self, request: GetPoolsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_interest_v1_liquidity_by_format<'life0, 'async_trait>( &'life0 self, request: GetLiquidityRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_interest_v1_swaps_by_format<'life0, 'async_trait>( &'life0 self, request: GetSwapsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_arche_collaterals_by_format<'life0, 'async_trait>( &'life0 self, request: GetCollateralsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_arche_loans_by_format<'life0, 'async_trait>( &'life0 self, request: GetLoansRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_arche_positions_by_format<'life0, 'async_trait>( &'life0 self, request: GetPositionsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_pyth_by_format<'life0, 'async_trait>( &'life0 self, request: GetPricesRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_move_balances_by_format<'life0, 'async_trait>( &'life0 self, request: GetBalancesRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

const MOVE_VALID_CHAINS: [ChainId; 3] = _

Source§

fn check_chain(&self, chains: &HashSet<ChainId>) -> Result<()>

Source§

impl Provider for WsProvider

Source§

fn try_new<'async_trait>( endpoint: String, is_secure: bool, username: Option<String>, password: Option<String>, ) -> Pin<Box<dyn Future<Output = Result<Self>> + Send + 'async_trait>>
where Self: 'async_trait,

Source§

fn get_status_by_format<'life0, 'async_trait>( &'life0 self, format: Format, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl UniswapV2Provider for WsProvider

Source§

fn get_pairs_by_format<'life0, 'async_trait>( &'life0 self, request: GetPairsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_prices_by_format<'life0, 'async_trait>( &'life0 self, request: GetPricesRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

impl UniswapV3Provider for WsProvider

Source§

fn get_fees_by_format<'life0, 'async_trait>( &'life0 self, request: GetFeesRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_pools_by_format<'life0, 'async_trait>( &'life0 self, request: GetPoolsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_positions_by_format<'life0, 'async_trait>( &'life0 self, request: GetPositionsRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_prices_by_format<'life0, 'async_trait>( &'life0 self, request: GetPricesRequest, format: Format, deltas: bool, ) -> Pin<Box<dyn Future<Output = StreamResponse<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. 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> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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
Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> JsonSchemaMaybe for T