Enum lychee_lib::CacheStatus
source · pub enum CacheStatus {
Ok(u16),
Error(Option<u16>),
Excluded,
Unsupported,
}Expand description
Representation of the status of a cached request. This is kept simple on purpose because the type gets serialized to a cache file and might need to be parsed by other tools or edited by humans.
Variants§
Ok(u16)
The cached request delivered a valid response
Error(Option<u16>)
The cached request failed before
Excluded
The request was excluded (skipped)
Unsupported
The protocol is not yet supported
Trait Implementations§
source§impl Clone for CacheStatus
impl Clone for CacheStatus
source§fn clone(&self) -> CacheStatus
fn clone(&self) -> CacheStatus
Returns a copy 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 CacheStatus
impl Debug for CacheStatus
source§impl<'de> Deserialize<'de> for CacheStatus
impl<'de> Deserialize<'de> for CacheStatus
source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Display for CacheStatus
impl Display for CacheStatus
source§impl From<&Status> for CacheStatus
impl From<&Status> for CacheStatus
source§impl Hash for CacheStatus
impl Hash for CacheStatus
source§impl Ord for CacheStatus
impl Ord for CacheStatus
source§fn cmp(&self, other: &CacheStatus) -> Ordering
fn cmp(&self, other: &CacheStatus) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for CacheStatus
impl PartialEq for CacheStatus
source§fn eq(&self, other: &CacheStatus) -> bool
fn eq(&self, other: &CacheStatus) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl PartialOrd for CacheStatus
impl PartialOrd for CacheStatus
source§fn partial_cmp(&self, other: &CacheStatus) -> Option<Ordering>
fn partial_cmp(&self, other: &CacheStatus) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self and other) and is used by the <=
operator. Read moresource§impl Serialize for CacheStatus
impl Serialize for CacheStatus
impl Copy for CacheStatus
impl Eq for CacheStatus
impl StructuralPartialEq for CacheStatus
Auto Trait Implementations§
impl RefUnwindSafe for CacheStatus
impl Send for CacheStatus
impl Sync for CacheStatus
impl Unpin for CacheStatus
impl UnwindSafe for CacheStatus
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
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.source§impl<T> FromResponse for Twhere
T: DeserializeOwned,
impl<T> FromResponse for Twhere
T: DeserializeOwned,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.