pub enum ProtocolState {
AwaitingResponse,
ProcessingTokens,
Draining,
Poisoned,
}Expand description
Internal protocol state for runtime management.
While connection states are tracked at compile-time via type-state, the protocol layer has runtime state that must be managed.
Variants§
AwaitingResponse
Awaiting response from server.
ProcessingTokens
Processing token stream.
Draining
Draining remaining tokens after cancellation.
Poisoned
Connection is in a broken state due to protocol error.
Implementations§
Trait Implementations§
Source§impl Clone for ProtocolState
impl Clone for ProtocolState
Source§fn clone(&self) -> ProtocolState
fn clone(&self) -> ProtocolState
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ProtocolState
impl Debug for ProtocolState
Source§impl Default for ProtocolState
impl Default for ProtocolState
Source§impl PartialEq for ProtocolState
impl PartialEq for ProtocolState
impl Copy for ProtocolState
impl Eq for ProtocolState
impl StructuralPartialEq for ProtocolState
Auto Trait Implementations§
impl Freeze for ProtocolState
impl RefUnwindSafe for ProtocolState
impl Send for ProtocolState
impl Sync for ProtocolState
impl Unpin for ProtocolState
impl UnwindSafe for ProtocolState
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.