Enum pingora_cache::RespCacheable
source · pub enum RespCacheable {
Cacheable(CacheMeta),
Uncacheable(NoCacheReason),
}Expand description
Response cacheable decision
Variants§
Cacheable(CacheMeta)
Uncacheable(NoCacheReason)
Implementations§
source§impl RespCacheable
impl RespCacheable
sourcepub fn is_cacheable(&self) -> bool
pub fn is_cacheable(&self) -> bool
Whether it is cacheable
sourcepub fn unwrap_meta(self) -> CacheMeta
pub fn unwrap_meta(self) -> CacheMeta
Unwrap RespCacheable to get the CacheMeta stored
§Panic
Panic when this object is not cacheable. Check Self::is_cacheable() first.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for RespCacheable
impl Send for RespCacheable
impl Sync for RespCacheable
impl Unpin for RespCacheable
impl !UnwindSafe for RespCacheable
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