pandora-0.4.6: A box of patterns and paradigms
Safe HaskellSafe-Inferred
LanguageHaskell2010

Pandora.Paradigm.Inventory.Store

Synopsis

Documentation

newtype Store s a Source #

Context based computation on value

Constructors

Store (((:*:) s :. (->) s) := a) 

Instances

Instances details
Monoidal (<--) ((->) :: Type -> Type -> Type) (:*:) (:*:) (Store s) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

Methods

unit :: Proxy (:*:) -> (Unit (:*:) -> a) <-- Store s a Source #

Semigroupoid (Lens Identity) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

Methods

(.) :: Lens Identity b c -> Lens Identity a b -> Lens Identity a c Source #

Semigroupoid (Lens Maybe) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

Methods

(.) :: Lens Maybe b c -> Lens Maybe a b -> Lens Maybe a c Source #

Category (Lens Identity) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

Category (Lens Maybe) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

Interpreted (Store s) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

Associated Types

type Primary (Store s) a Source #

Methods

run :: Store s a -> Primary (Store s) a Source #

unite :: Primary (Store s) a -> Store s a Source #

(||=) :: Interpreted u => (Primary (Store s) a -> Primary u b) -> Store s a -> u b Source #

(=||) :: Interpreted u => (Store s a -> u b) -> Primary (Store s) a -> Primary u b Source #

(<$||=) :: (Covariant (->) (->) j, Interpreted u) => (Primary (Store s) a -> Primary u b) -> (j := Store s a) -> j := u b Source #

(<$$||=) :: (Covariant (->) (->) j, Covariant (->) (->) k, Interpreted u) => (Primary (Store s) a -> Primary u b) -> ((j :. k) := Store s a) -> (j :. k) := u b Source #

(<$$$||=) :: (Covariant (->) (->) j, Covariant (->) (->) k, Covariant (->) (->) l, Interpreted u) => (Primary (Store s) a -> Primary u b) -> ((j :. (k :. l)) := Store s a) -> (j :. (k :. l)) := u b Source #

(<$$$$||=) :: (Covariant (->) (->) j, Covariant (->) (->) k, Covariant (->) (->) l, Covariant (->) (->) m, Interpreted u) => (Primary (Store s) a -> Primary u b) -> ((j :. (k :. (l :. m))) := Store s a) -> (j :. (k :. (l :. m))) := u b Source #

(=||$>) :: (Covariant (->) (->) j, Interpreted u) => (Store s a -> u b) -> (j := Primary (Store s) a) -> j := Primary u b Source #

(=||$$>) :: (Covariant (->) (->) j, Covariant (->) (->) k, Interpreted u) => (Store s a -> u b) -> ((j :. k) := Primary (Store s) a) -> (j :. k) := Primary u b Source #

(=||$$$>) :: (Covariant (->) (->) j, Covariant (->) (->) k, Covariant (->) (->) l, Interpreted u) => (Store s a -> u b) -> ((j :. (k :. l)) := Primary (Store s) a) -> (j :. (k :. l)) := Primary u b Source #

(=||$$$$>) :: (Covariant (->) (->) j, Covariant (->) (->) k, Covariant (->) (->) l, Covariant (->) (->) m, Interpreted u) => (Store s a -> u b) -> ((j :. (k :. (l :. m))) := Primary (Store s) a) -> (j :. (k :. (l :. m))) := Primary u b Source #

Comonadic (Store s) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

Methods

bring :: forall (u :: Type -> Type). Extractable_ u => (Store s :< u) ~> Store s Source #

Semimonoidal (<--) (:*:) (:*:) (Store s :: Type -> Type) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

Methods

multiply :: forall (a :: k) (b :: k). (Store s a :*: Store s b) <-- Store s (a :*: b) Source #

Comonad (Store s) ((->) :: Type -> Type -> Type) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

Impliable (P_Q_T ((->) :: Type -> Type -> Type) Store Identity source target :: Type) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

Associated Types

type Arguments (P_Q_T (->) Store Identity source target) = (args :: Type) Source #

Methods

imply :: Arguments (P_Q_T (->) Store Identity source target) Source #

Impliable (P_Q_T ((->) :: Type -> Type -> Type) Store Maybe source target :: Type) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

Associated Types

type Arguments (P_Q_T (->) Store Maybe source target) = (args :: Type) Source #

Methods

imply :: Arguments (P_Q_T (->) Store Maybe source target) Source #

Invariant (Flip Store r) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

Methods

(<$<) :: (a -> b) -> (b -> a) -> Flip Store r a -> Flip Store r b Source #

invmap :: (a -> b) -> (b -> a) -> Flip Store r a -> Flip Store r b Source #

Invariant (Flip (Lens available) tgt) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

Methods

(<$<) :: (a -> b) -> (b -> a) -> Flip (Lens available) tgt a -> Flip (Lens available) tgt b Source #

invmap :: (a -> b) -> (b -> a) -> Flip (Lens available) tgt a -> Flip (Lens available) tgt b Source #

Extendable ((->) :: Type -> Type -> Type) (Store s) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

Methods

(<<=) :: (Store s a -> b) -> Store s a -> Store s b Source #

Covariant ((->) :: Type -> Type -> Type) ((->) :: Type -> Type -> Type) (Store s) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

Methods

(-<$>-) :: (a -> b) -> Store s a -> Store s b Source #

Adjoint ((->) :: Type -> Type -> Type) ((->) :: Type -> Type -> Type) (Store s) (State s) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory

Methods

(-|) :: (Store s a -> b) -> a -> State s b Source #

(|-) :: (a -> State s b) -> Store s a -> b Source #

type Primary (Store s) a Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

type Primary (Store s) a = ((:*:) s :. ((->) s :: Type -> Type)) := a
type Arguments (P_Q_T ((->) :: Type -> Type -> Type) Store Identity source target :: Type) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

type Arguments (P_Q_T ((->) :: Type -> Type -> Type) Store Identity source target :: Type) = (source -> target) -> (source -> target -> source) -> Lens Identity source target
type Arguments (P_Q_T ((->) :: Type -> Type -> Type) Store Maybe source target :: Type) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Optics

type Arguments (P_Q_T ((->) :: Type -> Type -> Type) Store Maybe source target :: Type) = (source -> Maybe target) -> (source -> Maybe target -> source) -> Lens Maybe source target
type Schematic Comonad (Store s) Source # 
Instance details

Defined in Pandora.Paradigm.Inventory.Store

type Schematic Comonad (Store s) = (:*:) s <:<.>:> ((->) s :: Type -> Type)

type Storable s x = Adaptable x (Store s) Source #

position :: Storable s t => t a -> s Source #

Get current index

look :: Storable s t => s -> a <:= t Source #

Given an index return value

retrofit :: (s -> s) -> Store s ~> Store s Source #

Change index with function