Copyright | 2013 Kei Hibino |
---|---|
License | BSD3 |
Maintainer | ex8k.hibino@gmail.com |
Stability | experimental |
Portability | unknown |
Safe Haskell | None |
Language | Haskell2010 |
This module defines typed projection path objects. Contains normal interfaces.
- data Pi r0 r1
- pfmap :: ProductConstructor (a -> b) => (a -> b) -> Pi r a -> Pi r b
- pap :: Pi r (a -> b) -> Pi r a -> Pi r b
- (<.>) :: Pi a b -> Pi b c -> Pi a c
- (<?.>) :: Pi a (Maybe b) -> Pi b c -> Pi a (Maybe c)
- (<?.?>) :: Pi a (Maybe b) -> Pi b (Maybe c) -> Pi a (Maybe c)
- id' :: PersistableWidth a => Pi a a
- fst' :: PersistableWidth a => Pi (a, b) a
- snd' :: (PersistableWidth a, PersistableWidth b) => Pi (a, b) b
Projection path
Projection path from type r0
into type r1
.
This type also indicate key object which type is r1
for record type r0
.
ProjectableApplicative (Pi a) | Compose projection path |
ProjectableFunctor (Pi a) | Compose seed of projection path |
pfmap :: ProductConstructor (a -> b) => (a -> b) -> Pi r a -> Pi r b Source
Projectable fmap of Pi
type.
(<?.?>) :: Pi a (Maybe b) -> Pi b (Maybe c) -> Pi a (Maybe c) infixl 8 Source
Compose projection path.
id' :: PersistableWidth a => Pi a a Source
Identity projection path.
:: PersistableWidth a | |
=> Pi (a, b) a | Projection path of fst. |
Projection path for fst of tuple.
:: (PersistableWidth a, PersistableWidth b) | |
=> Pi (a, b) b | Projection path of snd. |
Projection path for snd of tuple.