pub struct TlsConnector<S> { /* private fields */ }Expand description
Rustls connector factory
Implementations§
Source§impl<A> TlsConnector<Connector<A>>where
A: Address,
impl<A> TlsConnector<Connector<A>>where
A: Address,
pub fn new(config: ClientConfig) -> TlsConnector<Connector<A>>
Sourcepub fn connector<F, S>(
self,
f: impl IntoService<S, SharedCfg, Connect<A>>,
) -> TlsConnector<S>
pub fn connector<F, S>( self, f: impl IntoService<S, SharedCfg, Connect<A>>, ) -> TlsConnector<S>
Use connector to open connections.
Trait Implementations§
Source§impl<S> Clone for TlsConnector<S>where
S: Clone,
impl<S> Clone for TlsConnector<S>where
S: Clone,
Source§fn clone(&self) -> TlsConnector<S>
fn clone(&self) -> TlsConnector<S>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<S> Debug for TlsConnector<S>where
S: Debug,
impl<S> Debug for TlsConnector<S>where
S: Debug,
Source§type Error = Error<ConnectError>
type Error = Error<ConnectError>
Error produced while checking readiness or processing a request.
Source§async fn call(
&self,
req: Connect<A>,
ctx: Ctx<'_, TlsConnector<S>, SharedCfg>,
) -> Result<<TlsConnector<S> as Service<SharedCfg, Connect<A>>>::Res, <TlsConnector<S> as Service<SharedCfg, Connect<A>>>::Error>
async fn call( &self, req: Connect<A>, ctx: Ctx<'_, TlsConnector<S>, SharedCfg>, ) -> Result<<TlsConnector<S> as Service<SharedCfg, Connect<A>>>::Res, <TlsConnector<S> as Service<SharedCfg, Connect<A>>>::Error>
Processes a request and asynchronously returns the response. Read more
Source§async fn ready(
&self,
ctx: Ctx<'_, TlsConnector<S>, SharedCfg>,
) -> Result<(), <TlsConnector<S> as Service<SharedCfg, Connect<A>>>::Error>
async fn ready( &self, ctx: Ctx<'_, TlsConnector<S>, SharedCfg>, ) -> Result<(), <TlsConnector<S> as Service<SharedCfg, Connect<A>>>::Error>
Waits until the service is ready to process a request. Read more
Source§async fn shutdown(&self, ctx: Ctx<'_, TlsConnector<S>, SharedCfg>)
async fn shutdown(&self, ctx: Ctx<'_, TlsConnector<S>, SharedCfg>)
Shuts down the service. Read more
Source§fn map<F, Res>(self, f: F) -> ServiceChain<Map<F, Self, Res>, St, Req>
fn map<F, Res>(self, f: F) -> ServiceChain<Map<F, Self, Res>, St, Req>
Maps this service’s output to a different type, returning a new service. Read more
Source§fn map_err<F, E>(self, f: F) -> ServiceChain<MapErr<F, Self, E>, St, Req>
fn map_err<F, E>(self, f: F) -> ServiceChain<MapErr<F, Self, E>, St, Req>
Maps this service’s error to a different type, returning a new service. Read more
Auto Trait Implementations§
impl<S> !RefUnwindSafe for TlsConnector<S>
impl<S> !UnwindSafe for TlsConnector<S>
impl<S> Freeze for TlsConnector<S>where
S: Freeze,
impl<S> Send for TlsConnector<S>where
S: Send,
impl<S> Sync for TlsConnector<S>where
S: Sync,
impl<S> Unpin for TlsConnector<S>where
S: Unpin,
impl<S> UnsafeUnpin for TlsConnector<S>where
S: UnsafeUnpin,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<S, St, Req> IntoService<S, St, Req> for Swhere
S: Service<St, Req>,
impl<S, St, Req> IntoService<S, St, Req> for Swhere
S: Service<St, Req>,
Source§fn into_service(self) -> S
fn into_service(self) -> S
Converts this value into a service.