lens-1.1: Families of Lenses, Folds and Traversals

PortabilityRank2Types
Stabilityprovisional
MaintainerEdward Kmett <ekmett@gmail.com>
Safe HaskellSafe-Infered

Control.Lens.Internal

Contents

Description

These are some of the explicit Functor instances that leak into the type signatures of Control.Lens. You shouldn't need to import this module directly, unless you are coming up with a whole new kind of "Family" and need to add instances.

Synopsis

Implementation details

data IndexedStore c d a Source

The indexed store can be used to characterize a LensFamily and is used by clone

Constructors

IndexedStore (d -> a) c 

Instances

newtype Focusing m c a Source

Used by Focus

Constructors

Focusing 

Fields

unfocusing :: m (c, a)
 

Instances

Monad m => Functor (Focusing m c) 
(Monad m, Monoid c) => Applicative (Focusing m c) 

newtype Traversed f Source

Used internally by traverseOf_, mapM_ and the like.

Constructors

Traversed 

Fields

getTraversed :: f ()
 

Instances

newtype Action m Source

Used internally by mapM_ and the like.

Constructors

Action 

Fields

getAction :: m ()
 

Instances

Monad m => Monoid (Action m) 

newtype AppliedState f a Source

Applicative composition of State Int with a Functor, used by elementOf, elementsOf, traverseElement, traverseElementsOf

Constructors

AppliedState 

Fields

runAppliedState :: Int -> (f a, Int)
 

newtype Backwards f a Source

Run an Applicative backwards

Constructors

Backwards 

Fields

getBackwards :: f a
 

data Min a Source

Used for minimumOf

Constructors

NoMin 
Min a 

Instances

Ord a => Monoid (Min a) 

getMin :: Min a -> Maybe aSource

Obtain the minimum

data Max a Source

Used for maximumOf

Constructors

NoMax 
Max a 

Instances

Ord a => Monoid (Max a) 

getMax :: Max a -> Maybe aSource

Obtain the maximum