data-layer-1.0.4: Data layering utilities. Layer is a data-type which wrapps other one, but keeping additional information. If you want to access content of simple newtype object, use Lens.Wrapper instead.

Safe HaskellNone
LanguageHaskell2010

Data.Layer

Documentation

type family Unlayered l Source

Instances

type Unlayered (Cover a) = a Source 

class Layered l where Source

Minimal complete definition

Nothing

Methods

layered :: Lens' l (Unlayered l) Source

Instances

class TransLayered l l' where Source

Minimal complete definition

Nothing

Methods

transLayered :: Lens l l' (Unlayered l) (Unlayered l') Source

class IsLayer l where Source

Methods

layer :: Unlayered l -> l Source

class LayeredM m l where Source

Minimal complete definition

Nothing

Methods

viewLayeredM :: l -> m (Unlayered l) Source

setLayeredM :: Unlayered l -> l -> m l Source

unlayerM :: LayeredM m l => l -> m (Unlayered l) Source

withLayeredM :: (LayeredM m a, Monad m) => (Unlayered a -> m (Unlayered a)) -> a -> m a Source

withLayeredM' :: (LayeredM m a, Monad m) => (Unlayered a -> Unlayered a) -> a -> m a Source

class LayerConstructor m l where Source

Methods

constructLayer :: Unlayered l -> m l Source