Skip to main content

IpProxyLoader

Trait IpProxyLoader 

Source
pub trait IpProxyLoader: Send + Sync {
    // Required methods
    fn get_ip_proxies<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<IpProxy>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn is_retry_code(&self, code: &u16) -> bool;
    fn get_name(&self) -> String;
    fn get_weight(&self) -> u32;
    fn get_config(&self) -> &IpProvider;
    fn health_check<'life0, 'life1, 'async_trait>(
        &'life0 self,
        proxy: &'life1 IpProxy,
    ) -> Pin<Box<dyn Future<Output = bool> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}

Required Methods§

Source

fn get_ip_proxies<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Vec<IpProxy>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn is_retry_code(&self, code: &u16) -> bool

Source

fn get_name(&self) -> String

Source

fn get_weight(&self) -> u32

Source

fn get_config(&self) -> &IpProvider

Source

fn health_check<'life0, 'life1, 'async_trait>( &'life0 self, proxy: &'life1 IpProxy, ) -> Pin<Box<dyn Future<Output = bool> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§