Struct tls_api::TlsConnectorBuilderBox
source · [−]pub struct TlsConnectorBuilderBox(_);
Expand description
TlsConnector
without type parameter.
Implementation can be switched without parameterizing every function.
Implementations
sourceimpl TlsConnectorBuilderBox
impl TlsConnectorBuilderBox
sourcepub fn build(self) -> Result<TlsConnectorBox>
pub fn build(self) -> Result<TlsConnectorBox>
Build a connector.
sourcepub fn set_alpn_protocols(&mut self, protocols: &[&[u8]]) -> Result<()>
pub fn set_alpn_protocols(&mut self, protocols: &[&[u8]]) -> Result<()>
Set ALPN-protocols to negotiate.
This operations fails is not TlsConnector::SUPPORTS_ALPN
.
sourcepub fn set_verify_hostname(&mut self, verify: bool) -> Result<()>
pub fn set_verify_hostname(&mut self, verify: bool) -> Result<()>
Should hostname verification be performed? Use carefully, it opens the door to MITM attacks.
Auto Trait Implementations
impl !RefUnwindSafe for TlsConnectorBuilderBox
impl Send for TlsConnectorBuilderBox
impl !Sync for TlsConnectorBuilderBox
impl Unpin for TlsConnectorBuilderBox
impl !UnwindSafe for TlsConnectorBuilderBox
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
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