invertible-0.1.2: bidirectional arrows, bijective functions, and invariant functors

Safe HaskellSafe
LanguageHaskell2010

Data.Invertible.Monoid

Description

Bidirectional transforms for Data.Monoid.

Synopsis

Documentation

newtype BiEndo a Source #

The monoid of endomorphisms under composition.

Constructors

BiEndo 

Fields

Instances

Functor BiEndo Source # 

Methods

fmap :: (a <-> b) -> BiEndo a -> BiEndo b Source #

Monoid (BiEndo a) Source # 

Methods

mempty :: BiEndo a #

mappend :: BiEndo a -> BiEndo a -> BiEndo a #

mconcat :: [BiEndo a] -> BiEndo a #

dual :: a <-> Dual a Source #

(Un)wrap the Dual monoid.

endo :: (a -> a) <-> Endo a Source #

(Un)wrap the Endo monoid.

biEndo :: (a <-> a) <-> BiEndo a Source #

(Un)wrap the BiEndo monoid.

all :: Bool <-> All Source #

(Un)wrap the All monoid.

any :: Bool <-> Any Source #

(Un)wrap the Any monoid.

sum :: a <-> Sum a Source #

(Un)wrap the Sum monoid.

product :: a <-> Product a Source #

(Un)wrap the Product monoid.

first :: Maybe a <-> First a Source #

(Un)wrap the First monoid.

last :: Maybe a <-> Last a Source #

(Un)wrap the Last monoid.

alt :: f a <-> Alt f a Source #

(Un)wrap the Last monoid.