Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data Comparison
- class Debatable a where
- weigh :: a -> a -> Comparison
- data Front a
- data Strata a
- singleton :: a -> Front a
- stratum :: a -> Strata a
- getStrata :: Strata a -> [Front a]
- getFront :: Front a -> [a]
- quota :: Int -> Strata a -> Strata a
- nestedFold :: (Monoid m, Monoid n) => (a -> m) -> (m -> n) -> Strata a -> n
Documentation
data Comparison Source #
The outcome of comparing two items by possibly multiple contradicting criteria.
Dominated | Where the second item is preferred by all used criteria |
WeakTie | Where no item is preferred by any used criterion |
StrongTie | Where each item is preferred by at least one criterion |
Dominates | Where the first item is preferred by all used critera |
Instances
class Debatable a where Source #
Items which can be compared by possibly multiple criteria contradicting criteria
weigh :: a -> a -> Comparison Source #
Instances
Debatable Double Source # | |
Defined in Math.ParetoFront | |
Debatable Float Source # | |
Defined in Math.ParetoFront | |
Debatable Int Source # | |
Defined in Math.ParetoFront | |
Debatable Integer Source # | |
Defined in Math.ParetoFront | |
Ord a => Debatable (Min a) Source # | |
Defined in Math.ParetoFront | |
Ord a => Debatable (Max a) Source # | |
Defined in Math.ParetoFront | |
Debatable a => Debatable (Down a) Source # | |
Defined in Math.ParetoFront | |
(Debatable a, Debatable b) => Debatable (a, b) Source # | |
Defined in Math.ParetoFront weigh :: (a, b) -> (a, b) -> Comparison Source # | |
Debatable a => Debatable (Arg a b) Source # | |
Defined in Math.ParetoFront | |
(Debatable a, Debatable b, Debatable c) => Debatable (a, b, c) Source # | |
Defined in Math.ParetoFront weigh :: (a, b, c) -> (a, b, c) -> Comparison Source # | |
(Debatable a, Debatable b, Debatable c, Debatable d) => Debatable (a, b, c, d) Source # | |
Defined in Math.ParetoFront weigh :: (a, b, c, d) -> (a, b, c, d) -> Comparison Source # |
A collection of items where no item is preferred by all criteria.
Instances
Foldable Front Source # | |
Defined in Math.ParetoFront fold :: Monoid m => Front m -> m # foldMap :: Monoid m => (a -> m) -> Front a -> m # foldMap' :: Monoid m => (a -> m) -> Front a -> m # foldr :: (a -> b -> b) -> b -> Front a -> b # foldr' :: (a -> b -> b) -> b -> Front a -> b # foldl :: (b -> a -> b) -> b -> Front a -> b # foldl' :: (b -> a -> b) -> b -> Front a -> b # foldr1 :: (a -> a -> a) -> Front a -> a # foldl1 :: (a -> a -> a) -> Front a -> a # elem :: Eq a => a -> Front a -> Bool # maximum :: Ord a => Front a -> a # minimum :: Ord a => Front a -> a # | |
Show a => Show (Front a) Source # | |
Debatable a => Semigroup (Front a) Source # | Where two |
Debatable a => Monoid (Front a) Source # | |
A series of Front
s such that each subsequent Front
consists of
items for which some item in the previous front is preferable by all
criteria.
Instances
Foldable Strata Source # | |
Defined in Math.ParetoFront fold :: Monoid m => Strata m -> m # foldMap :: Monoid m => (a -> m) -> Strata a -> m # foldMap' :: Monoid m => (a -> m) -> Strata a -> m # foldr :: (a -> b -> b) -> b -> Strata a -> b # foldr' :: (a -> b -> b) -> b -> Strata a -> b # foldl :: (b -> a -> b) -> b -> Strata a -> b # foldl' :: (b -> a -> b) -> b -> Strata a -> b # foldr1 :: (a -> a -> a) -> Strata a -> a # foldl1 :: (a -> a -> a) -> Strata a -> a # elem :: Eq a => a -> Strata a -> Bool # maximum :: Ord a => Strata a -> a # minimum :: Ord a => Strata a -> a # | |
Show a => Show (Strata a) Source # | |
Debatable a => Semigroup (Strata a) Source # | |
Debatable a => Monoid (Strata a) Source # | |