kan-extensions-5.0.2: Kan extensions, Kan lifts, various forms of the Yoneda lemma, and (co)density (co)monads

Copyright(C) 2013-2016 Edward Kmett
LicenseBSD-style (see the file LICENSE)
MaintainerEdward Kmett <ekmett@gmail.com>
Stabilityprovisional
PortabilityGADTs, TFs, MPTCs
Safe HaskellTrustworthy
LanguageHaskell98

Data.Functor.Contravariant.Yoneda

Description

 

Synopsis

Documentation

newtype Yoneda f a Source #

Yoneda embedding for a presheaf

Constructors

Yoneda 

Fields

Instances

Contravariant (Yoneda f) Source # 

Methods

contramap :: (a -> b) -> Yoneda f b -> Yoneda f a #

(>$) :: b -> Yoneda f b -> Yoneda f a #

Representable f => Representable (Yoneda f) Source # 

Associated Types

type Rep (Yoneda f :: * -> *) :: * #

Methods

tabulate :: (a -> Rep (Yoneda f)) -> Yoneda f a #

index :: Yoneda f a -> a -> Rep (Yoneda f) #

contramapWithRep :: (b -> Either a (Rep (Yoneda f))) -> Yoneda f a -> Yoneda f b #

Adjunction f g => Adjunction (Yoneda f) (Yoneda g) Source # 

Methods

unit :: a -> Yoneda g (Yoneda f a) #

counit :: a -> Yoneda f (Yoneda g a) #

leftAdjunct :: (b -> Yoneda f a) -> a -> Yoneda g b #

rightAdjunct :: (a -> Yoneda g b) -> b -> Yoneda f a #

type Rep (Yoneda f) Source # 
type Rep (Yoneda f) = Rep f

lowerYoneda :: Yoneda f a -> f a Source #