Struct trillium_rustls::RustlsConnector
source · [−]pub struct RustlsConnector<C>(_);
Expand description
this struct provides rustls a trillium client connector implementation
Trait Implementations
sourceimpl<C: Clone> Clone for RustlsConnector<C>
impl<C: Clone> Clone for RustlsConnector<C>
sourcefn clone(&self) -> RustlsConnector<C>
fn clone(&self) -> RustlsConnector<C>
Returns a copy of the value. Read more
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl<C: Connector> Connector for RustlsConnector<C>
impl<C: Connector> Connector for RustlsConnector<C>
type Config = RustlsConfig<<C as Connector>::Config>
type Config = RustlsConfig<<C as Connector>::Config>
A type that can be used to configure this Connector. It will be passed into [
Connector::connect
].type Transport = RustlsTransport<<C as Connector>::Transport>
type Transport = RustlsTransport<<C as Connector>::Transport>
The async read + write type for this connector, often a TcpStream or TlSStream
sourcefn peer_addr(transport: &Self::Transport) -> Result<SocketAddr>
fn peer_addr(transport: &Self::Transport) -> Result<SocketAddr>
A SocketAddr representation of the other side of this connection
sourcefn connect<'life0, 'life1, 'async_trait>(
url: &'life0 Url,
config: &'life1 Self::Config
) -> Pin<Box<dyn Future<Output = Result<Self::Transport>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn connect<'life0, 'life1, 'async_trait>(
url: &'life0 Url,
config: &'life1 Self::Config
) -> Pin<Box<dyn Future<Output = Result<Self::Transport>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Initiate a connection to the provided url, using the configuration. Read more
sourcefn spawn<Fut>(future: Fut)where
Fut: Future + Send + 'static,
<Fut as Future>::Output: Send,
fn spawn<Fut>(future: Fut)where
Fut: Future + Send + 'static,
<Fut as Future>::Output: Send,
Spawn and detach a task on the runtime. Although this may seem
unrelated to the purpose of a tcp connector, it is required as a
workaround for the absence of async drop in order to enable
keepalive connection pooling. TLS implementations that wrap a
runtime implementation should call through to the inner spawn. Read more
sourceimpl<C: Debug> Debug for RustlsConnector<C>
impl<C: Debug> Debug for RustlsConnector<C>
impl<C: Copy> Copy for RustlsConnector<C>
Auto Trait Implementations
impl<C> RefUnwindSafe for RustlsConnector<C>where
C: RefUnwindSafe,
impl<C> Send for RustlsConnector<C>where
C: Send,
impl<C> Sync for RustlsConnector<C>where
C: Sync,
impl<C> Unpin for RustlsConnector<C>where
C: Unpin,
impl<C> UnwindSafe for RustlsConnector<C>where
C: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more