pub enum CacheQueryRule {
Ignore(Vec<String>),
Allow(Vec<String>),
}Expand description
Which parameters of the query a cache key is made of.
Variants§
Implementations§
Source§impl CacheQueryRule
impl CacheQueryRule
Sourcepub fn key_query(&self, query: &str) -> String
pub fn key_query(&self, query: &str) -> String
The query string a cache key is made of: the parameters the rule keeps, in the order of their names.
?b=2&a=1 and ?a=1&b=2 are the same page and were two entries,
and a tracking parameter (utm_source, fbclid) made one entry
per visitor. Parameters of the same name keep the order they came
in, which is theirs to mean something. Names are compared as they
are written, not decoded.
Trait Implementations§
Source§impl Clone for CacheQueryRule
impl Clone for CacheQueryRule
Source§impl Debug for CacheQueryRule
impl Debug for CacheQueryRule
Source§impl PartialEq for CacheQueryRule
impl PartialEq for CacheQueryRule
impl StructuralPartialEq for CacheQueryRule
Auto Trait Implementations§
impl Freeze for CacheQueryRule
impl RefUnwindSafe for CacheQueryRule
impl Send for CacheQueryRule
impl Sync for CacheQueryRule
impl Unpin for CacheQueryRule
impl UnsafeUnpin for CacheQueryRule
impl UnwindSafe for CacheQueryRule
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