Skip to main content

Module predicate

Module predicate 

Expand description

Predicates for influencing compression of responses.

Structs§

Always
Predicate to always compress.
And
Two predicates combined into one.
DefaultPredicate
The default predicate used by Compression and CompressionLayer.
DefaultStreamPredicate
MirrorDecompressed
Predicate that enables compression only for responses previously decompressed by Rama’s crate::layer::decompression::DecompressionLayer, while preferring the original upstream encoding for recompression.
NotForContentType
Predicate that wont allow responses with a specific content-type to be compressed.
SizeAbove
Predicate that will only allow compression of responses above a certain size.

Enums§

PreferredEncoding
Preferred response encoding requested by a compression predicate.

Traits§

Predicate
Predicate used to determine if a response should be compressed or not.