Safe Haskell | Safe-Inferred |
---|
Defines the Match
type class, designed to unify types on the
matching functions in the Media module.
- class Match a where
- matches :: a -> a -> Bool
- moreSpecificThan :: a -> a -> Bool
- mostSpecific :: Match a => a -> a -> a
Documentation
Defines methods for a type whose values can be matched against each other in terms of a HTTP media header.
This allows functions to work on both the standard Accept header and others such as Accept-Language that still may use quality values.
mostSpecific :: Match a => a -> a -> aSource
Evaluates to whichever argument is more specific. Left biased.