pub enum MaybeHttpsStream<T> {
Http(T),
Https(SslStream<T>),
}Expand description
A stream which may be wrapped with TLS.
Variants§
Trait Implementations§
Source§impl<T> Connection for MaybeHttpsStream<T>where
T: Connection,
Available on crate feature hyper1 only.
impl<T> Connection for MaybeHttpsStream<T>where
T: Connection,
Available on crate feature
hyper1 only.Source§impl<T> Debug for MaybeHttpsStream<T>
impl<T> Debug for MaybeHttpsStream<T>
Source§impl<T> Read for MaybeHttpsStream<T>
Available on crate feature hyper1 only.
impl<T> Read for MaybeHttpsStream<T>
Available on crate feature
hyper1 only.Source§impl<T> Write for MaybeHttpsStream<T>
Available on crate feature hyper1 only.
impl<T> Write for MaybeHttpsStream<T>
Available on crate feature
hyper1 only.Source§fn poll_write(
self: Pin<&mut Self>,
ctx: &mut Context<'_>,
buf: &[u8],
) -> Poll<Result<usize>>
fn poll_write( self: Pin<&mut Self>, ctx: &mut Context<'_>, buf: &[u8], ) -> Poll<Result<usize>>
Attempt to write bytes from
buf into the destination. Read moreSource§fn poll_flush(self: Pin<&mut Self>, ctx: &mut Context<'_>) -> Poll<Result<()>>
fn poll_flush(self: Pin<&mut Self>, ctx: &mut Context<'_>) -> Poll<Result<()>>
Attempts to flush the object. Read more
Source§fn poll_shutdown(
self: Pin<&mut Self>,
ctx: &mut Context<'_>,
) -> Poll<Result<()>>
fn poll_shutdown( self: Pin<&mut Self>, ctx: &mut Context<'_>, ) -> Poll<Result<()>>
Attempts to shut down this writer.
Source§fn is_write_vectored(&self) -> bool
fn is_write_vectored(&self) -> bool
Returns whether this writer has an efficient
poll_write_vectored
implementation. Read moreAuto Trait Implementations§
impl<T> Freeze for MaybeHttpsStream<T>where
T: Freeze,
impl<T> RefUnwindSafe for MaybeHttpsStream<T>where
T: RefUnwindSafe,
impl<T> Send for MaybeHttpsStream<T>where
T: Send,
impl<T> Sync for MaybeHttpsStream<T>where
T: Sync,
impl<T> Unpin for MaybeHttpsStream<T>where
T: Unpin,
impl<T> UnwindSafe for MaybeHttpsStream<T>where
T: UnwindSafe,
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