monoids-0.2.0.1: Monoids, specialized containers and a general map/reduce framework
Source code
Contents
Index
Data.Monoid.Union
Contents
Unions of Containers
Unions of Containers of Monoids
Synopsis
module
Data.Monoid.Reducer
class
HasUnion
f
where
empty
:: f
union
:: f -> f -> f
newtype
Union
f =
Union
{
getUnion
:: f
}
class
Functor
f =>
HasUnionWith
f
where
unionWith
:: (a -> a -> a) -> f a -> f a -> f a
emptyWith
:: f a
newtype
UnionWith
f m =
UnionWith
{
getUnionWith
:: f m
}
Documentation
module
Data.Monoid.Reducer
Unions of Containers
class
HasUnion
f
where
Source
A Container suitable for the
Union
Monoid
Methods
empty
:: f
Source
union
:: f -> f -> f
Source
Instances
HasUnion
IntSet
Eq
a =>
HasUnion
([] a)
HasUnion
(
IntMap
a)
Ord
a =>
HasUnion
(
Set
a)
Ord
k =>
HasUnion
(
Map
k a)
newtype
Union
f
Source
The
Monoid
(
union
,
empty
)
Constructors
Union
getUnion
:: f
Instances
Functor
Union
HasUnion
f =>
Reducer
f (
Union
f)
Eq
f =>
Eq
(
Union
f)
Ord
f =>
Ord
(
Union
f)
Read
f =>
Read
(
Union
f)
Show
f =>
Show
(
Union
f)
HasUnion
f =>
Monoid
(
Union
f)
Unions of Containers of Monoids
class
Functor
f =>
HasUnionWith
f
where
Source
Polymorphic containers that we can supply an operation to handle unions with
Methods
unionWith
:: (a -> a -> a) -> f a -> f a -> f a
Source
emptyWith
:: f a
Source
Instances
HasUnionWith
IntMap
Ord
k =>
HasUnionWith
(
Map
k)
newtype
UnionWith
f m
Source
The
Monoid
('unionWith mappend',
empty
)
for containers full of monoids.
Constructors
UnionWith
getUnionWith
:: f m
Instances
Monad
f =>
Monad
(
UnionWith
f)
Functor
f =>
Functor
(
UnionWith
f)
(
HasUnionWith
f,
Monoid
m) =>
Reducer
(f m) (
UnionWith
f m)
Eq
(f m) =>
Eq
(
UnionWith
f m)
Ord
(f m) =>
Ord
(
UnionWith
f m)
Read
(f m) =>
Read
(
UnionWith
f m)
Show
(f m) =>
Show
(
UnionWith
f m)
(
HasUnionWith
f,
Monoid
m) =>
Monoid
(
UnionWith
f m)
Produced by
Haddock
version 2.4.2