Trait rama::http::layer::compression::Predicate
pub trait Predicate: Clone {
// Required method
fn should_compress<B>(&self, response: &Response<B>) -> bool
where B: Body;
// Provided method
fn and<Other>(self, other: Other) -> And<Self, Other>
where Self: Sized,
Other: Predicate { ... }
}
Expand description
Predicate used to determine if a response should be compressed or not.
Required Methods§
fn should_compress<B>(&self, response: &Response<B>) -> boolwhere
B: Body,
fn should_compress<B>(&self, response: &Response<B>) -> boolwhere
B: Body,
Should this response be compressed or not?
Provided Methods§
Object Safety§
This trait is not object safe.