Copyright | (C) 2012-15 Edward Kmett |
---|---|
License | BSD-style (see the file LICENSE) |
Maintainer | Edward Kmett <ekmett@gmail.com> |
Stability | provisional |
Portability | Rank2Types |
Safe Haskell | Safe-Inferred |
Language | Haskell98 |
- newtype ReifiedLens s t a b = Lens {}
- type ReifiedLens' s a = ReifiedLens s s a a
- newtype ReifiedIndexedLens i s t a b = IndexedLens {
- runIndexedLens :: IndexedLens i s t a b
- type ReifiedIndexedLens' i s a = ReifiedIndexedLens i s s a a
- newtype ReifiedIndexedTraversal i s t a b = IndexedTraversal {
- runIndexedTraversal :: IndexedTraversal i s t a b
- type ReifiedIndexedTraversal' i s a = ReifiedIndexedTraversal i s s a a
- newtype ReifiedTraversal s t a b = Traversal {
- runTraversal :: Traversal s t a b
- type ReifiedTraversal' s a = ReifiedTraversal s s a a
- newtype ReifiedGetter s a = Getter {}
- newtype ReifiedIndexedGetter i s a = IndexedGetter {
- runIndexedGetter :: IndexedGetter i s a
- newtype ReifiedFold s a = Fold {}
- newtype ReifiedIndexedFold i s a = IndexedFold {
- runIndexedFold :: IndexedFold i s a
- newtype ReifiedSetter s t a b = Setter {}
- type ReifiedSetter' s a = ReifiedSetter s s a a
- newtype ReifiedIndexedSetter i s t a b = IndexedSetter {
- runIndexedSetter :: IndexedSetter i s t a b
- type ReifiedIndexedSetter' i s a = ReifiedIndexedSetter i s s a a
- newtype ReifiedIso s t a b = Iso {}
- type ReifiedIso' s a = ReifiedIso s s a a
- newtype ReifiedPrism s t a b = Prism {}
- type ReifiedPrism' s a = ReifiedPrism s s a a
Documentation
>>>
import Control.Lens
newtype ReifiedLens s t a b Source
Reify a Lens
so it can be stored safely in a container.
type ReifiedLens' s a = ReifiedLens s s a a Source
typeReifiedLens'
=Simple
ReifiedLens
newtype ReifiedIndexedLens i s t a b Source
Reify an IndexedLens
so it can be stored safely in a container.
IndexedLens | |
|
type ReifiedIndexedLens' i s a = ReifiedIndexedLens i s s a a Source
typeReifiedIndexedLens'
i =Simple
(ReifiedIndexedLens
i)
newtype ReifiedIndexedTraversal i s t a b Source
Reify an IndexedTraversal
so it can be stored safely in a container.
IndexedTraversal | |
|
type ReifiedIndexedTraversal' i s a = ReifiedIndexedTraversal i s s a a Source
typeReifiedIndexedTraversal'
i =Simple
(ReifiedIndexedTraversal
i)
newtype ReifiedTraversal s t a b Source
A form of Traversal
that can be stored monomorphically in a container.
Traversal | |
|
type ReifiedTraversal' s a = ReifiedTraversal s s a a Source
newtype ReifiedGetter s a Source
Reify a Getter
so it can be stored safely in a container.
This can also be useful when combining getters in novel ways, as
ReifiedGetter
is isomorphic to '(->)' and provides similar instances.
>>>
("hello","world","!!!")^.runGetter ((,) <$> Getter _2 <*> Getter (_1.to length))
("world",5)
newtype ReifiedIndexedGetter i s a Source
Reify an IndexedGetter
so it can be stored safely in a container.
IndexedGetter | |
|
Representable (ReifiedIndexedGetter i) | |
Strong (ReifiedIndexedGetter i) | |
Profunctor (ReifiedIndexedGetter i) | |
Functor (ReifiedIndexedGetter i s) | |
Semigroup i => Apply (ReifiedIndexedGetter i s) | |
type Rep (ReifiedIndexedGetter i) = (,) i |
newtype ReifiedFold s a Source
Reify a Fold
so it can be stored safely in a container.
This can also be useful for creatively combining folds as
is isomorphic to ReifiedFold
sReaderT s []
and provides similar
instances.
>>>
("hello","world")^..runFold ((,) <$> Fold _2 <*> Fold both)
[("world","hello"),("world","world")]
Arrow ReifiedFold | |
ArrowChoice ReifiedFold | |
ArrowApply ReifiedFold | |
Representable ReifiedFold | |
Strong ReifiedFold | |
Choice ReifiedFold | |
Profunctor ReifiedFold | |
Category * ReifiedFold | |
MonadReader s (ReifiedFold s) | |
Alternative (ReifiedFold s) | |
Monad (ReifiedFold s) | |
Functor (ReifiedFold s) | |
MonadPlus (ReifiedFold s) | |
Applicative (ReifiedFold s) | |
Plus (ReifiedFold s) | |
Alt (ReifiedFold s) | |
Apply (ReifiedFold s) | |
Bind (ReifiedFold s) | |
Monoid (ReifiedFold s a) | |
Semigroup (ReifiedFold s a) | |
type Rep ReifiedFold = [] |
newtype ReifiedIndexedFold i s a Source
IndexedFold | |
|
Representable (ReifiedIndexedFold i) | |
Strong (ReifiedIndexedFold i) | |
Profunctor (ReifiedIndexedFold i) | |
Functor (ReifiedIndexedFold i s) | |
Plus (ReifiedIndexedFold i s) | |
Alt (ReifiedIndexedFold i s) | |
Monoid (ReifiedIndexedFold i s a) | |
Semigroup (ReifiedIndexedFold i s a) | |
type Rep (ReifiedIndexedFold i) = Compose [] ((,) i) |
newtype ReifiedSetter s t a b Source
Reify a Setter
so it can be stored safely in a container.
type ReifiedSetter' s a = ReifiedSetter s s a a Source
typeReifiedSetter'
=Simple
ReifiedSetter
newtype ReifiedIndexedSetter i s t a b Source
Reify an IndexedSetter
so it can be stored safely in a container.
IndexedSetter | |
|
type ReifiedIndexedSetter' i s a = ReifiedIndexedSetter i s s a a Source
typeReifiedIndexedSetter'
i =Simple
(ReifiedIndexedSetter
i)
newtype ReifiedIso s t a b Source
Reify an Iso
so it can be stored safely in a container.
type ReifiedIso' s a = ReifiedIso s s a a Source
typeReifiedIso'
=Simple
ReifiedIso
newtype ReifiedPrism s t a b Source
Reify a Prism
so it can be stored safely in a container.
type ReifiedPrism' s a = ReifiedPrism s s a a Source
typeReifiedPrism'
=Simple
ReifiedPrism