Trait gio::prelude::SocketClientExt

source ·
pub trait SocketClientExt: IsA<SocketClient> + Sealed + 'static {
Show 43 methods // Provided methods fn add_application_proxy(&self, protocol: &str) { ... } fn connect( &self, connectable: &impl IsA<SocketConnectable>, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<SocketConnection, Error> { ... } fn connect_async<P: FnOnce(Result<SocketConnection, Error>) + 'static>( &self, connectable: &impl IsA<SocketConnectable>, cancellable: Option<&impl IsA<Cancellable>>, callback: P ) { ... } fn connect_future( &self, connectable: &(impl IsA<SocketConnectable> + Clone + 'static) ) -> Pin<Box_<dyn Future<Output = Result<SocketConnection, Error>> + 'static>> { ... } fn connect_to_host( &self, host_and_port: &str, default_port: u16, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<SocketConnection, Error> { ... } fn connect_to_host_async<P: FnOnce(Result<SocketConnection, Error>) + 'static>( &self, host_and_port: &str, default_port: u16, cancellable: Option<&impl IsA<Cancellable>>, callback: P ) { ... } fn connect_to_host_future( &self, host_and_port: &str, default_port: u16 ) -> Pin<Box_<dyn Future<Output = Result<SocketConnection, Error>> + 'static>> { ... } fn connect_to_service( &self, domain: &str, service: &str, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<SocketConnection, Error> { ... } fn connect_to_service_async<P: FnOnce(Result<SocketConnection, Error>) + 'static>( &self, domain: &str, service: &str, cancellable: Option<&impl IsA<Cancellable>>, callback: P ) { ... } fn connect_to_service_future( &self, domain: &str, service: &str ) -> Pin<Box_<dyn Future<Output = Result<SocketConnection, Error>> + 'static>> { ... } fn connect_to_uri( &self, uri: &str, default_port: u16, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<SocketConnection, Error> { ... } fn connect_to_uri_async<P: FnOnce(Result<SocketConnection, Error>) + 'static>( &self, uri: &str, default_port: u16, cancellable: Option<&impl IsA<Cancellable>>, callback: P ) { ... } fn connect_to_uri_future( &self, uri: &str, default_port: u16 ) -> Pin<Box_<dyn Future<Output = Result<SocketConnection, Error>> + 'static>> { ... } fn enables_proxy(&self) -> bool { ... } fn family(&self) -> SocketFamily { ... } fn local_address(&self) -> Option<SocketAddress> { ... } fn protocol(&self) -> SocketProtocol { ... } fn proxy_resolver(&self) -> ProxyResolver { ... } fn socket_type(&self) -> SocketType { ... } fn timeout(&self) -> u32 { ... } fn is_tls(&self) -> bool { ... } fn tls_validation_flags(&self) -> TlsCertificateFlags { ... } fn set_enable_proxy(&self, enable: bool) { ... } fn set_family(&self, family: SocketFamily) { ... } fn set_local_address(&self, address: Option<&impl IsA<SocketAddress>>) { ... } fn set_protocol(&self, protocol: SocketProtocol) { ... } fn set_proxy_resolver( &self, proxy_resolver: Option<&impl IsA<ProxyResolver>> ) { ... } fn set_socket_type(&self, type_: SocketType) { ... } fn set_timeout(&self, timeout: u32) { ... } fn set_tls(&self, tls: bool) { ... } fn set_tls_validation_flags(&self, flags: TlsCertificateFlags) { ... } fn type_(&self) -> SocketType { ... } fn set_type(&self, type_: SocketType) { ... } fn connect_event<F: Fn(&Self, SocketClientEvent, &SocketConnectable, Option<&IOStream>) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_enable_proxy_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_family_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_local_address_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_protocol_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_proxy_resolver_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_timeout_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_tls_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_tls_validation_flags_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_type_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... }
}

Provided Methods§

source

fn add_application_proxy(&self, protocol: &str)

source

fn connect( &self, connectable: &impl IsA<SocketConnectable>, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<SocketConnection, Error>

source

fn connect_async<P: FnOnce(Result<SocketConnection, Error>) + 'static>( &self, connectable: &impl IsA<SocketConnectable>, cancellable: Option<&impl IsA<Cancellable>>, callback: P )

source

fn connect_future( &self, connectable: &(impl IsA<SocketConnectable> + Clone + 'static) ) -> Pin<Box_<dyn Future<Output = Result<SocketConnection, Error>> + 'static>>

source

fn connect_to_host( &self, host_and_port: &str, default_port: u16, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<SocketConnection, Error>

source

fn connect_to_host_async<P: FnOnce(Result<SocketConnection, Error>) + 'static>( &self, host_and_port: &str, default_port: u16, cancellable: Option<&impl IsA<Cancellable>>, callback: P )

source

fn connect_to_host_future( &self, host_and_port: &str, default_port: u16 ) -> Pin<Box_<dyn Future<Output = Result<SocketConnection, Error>> + 'static>>

source

fn connect_to_service( &self, domain: &str, service: &str, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<SocketConnection, Error>

source

fn connect_to_service_async<P: FnOnce(Result<SocketConnection, Error>) + 'static>( &self, domain: &str, service: &str, cancellable: Option<&impl IsA<Cancellable>>, callback: P )

source

fn connect_to_service_future( &self, domain: &str, service: &str ) -> Pin<Box_<dyn Future<Output = Result<SocketConnection, Error>> + 'static>>

source

fn connect_to_uri( &self, uri: &str, default_port: u16, cancellable: Option<&impl IsA<Cancellable>> ) -> Result<SocketConnection, Error>

source

fn connect_to_uri_async<P: FnOnce(Result<SocketConnection, Error>) + 'static>( &self, uri: &str, default_port: u16, cancellable: Option<&impl IsA<Cancellable>>, callback: P )

source

fn connect_to_uri_future( &self, uri: &str, default_port: u16 ) -> Pin<Box_<dyn Future<Output = Result<SocketConnection, Error>> + 'static>>

source

fn enables_proxy(&self) -> bool

source

fn family(&self) -> SocketFamily

source

fn local_address(&self) -> Option<SocketAddress>

source

fn protocol(&self) -> SocketProtocol

source

fn proxy_resolver(&self) -> ProxyResolver

source

fn socket_type(&self) -> SocketType

source

fn timeout(&self) -> u32

source

fn is_tls(&self) -> bool

source

fn tls_validation_flags(&self) -> TlsCertificateFlags

👎Deprecated: Since 2.72
source

fn set_enable_proxy(&self, enable: bool)

source

fn set_family(&self, family: SocketFamily)

source

fn set_local_address(&self, address: Option<&impl IsA<SocketAddress>>)

source

fn set_protocol(&self, protocol: SocketProtocol)

source

fn set_proxy_resolver(&self, proxy_resolver: Option<&impl IsA<ProxyResolver>>)

source

fn set_socket_type(&self, type_: SocketType)

source

fn set_timeout(&self, timeout: u32)

source

fn set_tls(&self, tls: bool)

source

fn set_tls_validation_flags(&self, flags: TlsCertificateFlags)

👎Deprecated: Since 2.72
source

fn type_(&self) -> SocketType

source

fn set_type(&self, type_: SocketType)

source

fn connect_event<F: Fn(&Self, SocketClientEvent, &SocketConnectable, Option<&IOStream>) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_enable_proxy_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_family_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

source

fn connect_local_address_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_protocol_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_proxy_resolver_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_timeout_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_tls_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

source

fn connect_tls_validation_flags_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

👎Deprecated: Since 2.72
source

fn connect_type_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

Object Safety§

This trait is not object safe.

Implementors§