#[non_exhaustive]pub enum Health {
Open,
Readable,
PeerClosed,
}Expand description
What TcpConnection::probe found, without waiting or consuming anything.
assert_ne!(net_io::Health::Open, net_io::Health::PeerClosed);Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Open
Connected, nothing waiting: safe to send a request on.
Readable
Bytes are waiting (on a TLS connection, possibly only records), or, on a stream other than TCP, bytes or the end of the stream.
PeerClosed
The peer sent FIN: the next read returns 0. A pooled connection in this state should be closed, not reused.
Trait Implementations§
impl Copy for Health
impl Eq for Health
impl StructuralPartialEq for Health
Auto Trait Implementations§
impl Forget for Health
impl Freeze for Health
impl Move for Health
impl RefUnwindSafe for Health
impl Send for Health
impl Sync for Health
impl Unpin for Health
impl UnsafeUnpin for Health
impl UnwindSafe for Health
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