polysemy-optics-0.1.0.2: Optics for Polysemy.

Optics.Polysemy

Synopsis

# Documentation

(&) :: a -> (a -> b) -> b infixl 1 #

& is a reverse application operator. This provides notational convenience. Its precedence is one higher than that of the forward application operator $, which allows & to be nested in $.

>>> 5 & (+1) & show
"6"


Since: base-4.8.0.0

(<&>) :: Functor f => f a -> (a -> b) -> f b infixl 1 #

Flipped version of <$>. (<&>) = flip fmap  #### Examples Expand Apply (+1) to a list, a Just and a Right: >>> Just 2 <&> (+1) Just 3  >>> [1,2,3] <&> (+1) [2,3,4]  >>> Right 3 <&> (+1) Right 4  Since: base-4.11.0.0 itoList :: FoldableWithIndex i f => f a -> [(i, a)] # Extract the key-value pairs from a structure. When you don't need access to the indices in the result, then toList is more flexible in what it accepts. toList ≡ map snd . itoList  ifor_ :: (FoldableWithIndex i t, Applicative f) => t a -> (i -> a -> f b) -> f () # Traverse elements with access to the index i, discarding the results (with the arguments flipped). ifor_ ≡ flip itraverse_  When you don't need access to the index then for_ is more flexible in what it accepts. for_ a ≡ ifor_ a . const  itraverse_ :: (FoldableWithIndex i t, Applicative f) => (i -> a -> f b) -> t a -> f () # Traverse elements with access to the index i, discarding the results. When you don't need access to the index then traverse_ is more flexible in what it accepts. traverse_ l = itraverse . const  ifor :: (TraversableWithIndex i t, Applicative f) => t a -> (i -> a -> f b) -> f (t b) # Traverse with an index (and the arguments flipped). for a ≡ ifor a . const ifor ≡ flip itraverse  class Functor f => FunctorWithIndex i (f :: Type -> Type) | f -> i where # A Functor with an additional index. Instances must satisfy a modified form of the Functor laws: imap f . imap g ≡ imap (\i -> f i . g i) imap (\_ a -> a) ≡ id  Minimal complete definition Nothing Methods imap :: (i -> a -> b) -> f a -> f b # Map with access to the index. #### Instances Instances details  The position in the list is available as the index. Instance detailsDefined in WithIndex Methodsimap :: (Int -> a -> b) -> [a] -> [b] # Same instance as for []. Instance detailsDefined in WithIndex Methodsimap :: (Int -> a -> b) -> ZipList a -> ZipList b # Instance detailsDefined in WithIndex Methodsimap :: (Int -> a -> b) -> NonEmpty a -> NonEmpty b # Instance detailsDefined in WithIndex Methodsimap :: (Int -> a -> b) -> IntMap a -> IntMap b # The position in the Seq is available as the index. Instance detailsDefined in WithIndex Methodsimap :: (Int -> a -> b) -> Seq a -> Seq b # Instance detailsDefined in WithIndex Methodsimap :: (() -> a -> b) -> Maybe a -> Maybe b # Instance detailsDefined in WithIndex Methodsimap :: (() -> a -> b) -> Par1 a -> Par1 b # Instance detailsDefined in WithIndex Methodsimap :: (() -> a -> b) -> Identity a -> Identity b # FunctorWithIndex k (Map k) Instance detailsDefined in WithIndex Methodsimap :: (k -> a -> b) -> Map k a -> Map k b # FunctorWithIndex k ((,) k) Instance detailsDefined in WithIndex Methodsimap :: (k -> a -> b) -> (k, a) -> (k, b) # Ix i => FunctorWithIndex i (Array i) Instance detailsDefined in WithIndex Methodsimap :: (i -> a -> b) -> Array i a -> Array i b # Instance detailsDefined in WithIndex Methodsimap :: (Void -> a -> b) -> V1 a -> V1 b # Instance detailsDefined in WithIndex Methodsimap :: (Void -> a -> b) -> U1 a -> U1 b # Instance detailsDefined in WithIndex Methodsimap :: (Void -> a -> b) -> Proxy a -> Proxy b # FunctorWithIndex i f => FunctorWithIndex i (Reverse f) Instance detailsDefined in WithIndex Methodsimap :: (i -> a -> b) -> Reverse f a -> Reverse f b # FunctorWithIndex i f => FunctorWithIndex i (Rec1 f) Instance detailsDefined in WithIndex Methodsimap :: (i -> a -> b) -> Rec1 f a -> Rec1 f b # FunctorWithIndex i m => FunctorWithIndex i (IdentityT m) Instance detailsDefined in WithIndex Methodsimap :: (i -> a -> b) -> IdentityT m a -> IdentityT m b # FunctorWithIndex i f => FunctorWithIndex i (Backwards f) Instance detailsDefined in WithIndex Methodsimap :: (i -> a -> b) -> Backwards f a -> Backwards f b # Instance detailsDefined in WithIndex Methodsimap :: (Void -> a -> b) -> Const e a -> Const e b # Instance detailsDefined in WithIndex Methodsimap :: (Void -> a -> b) -> Constant e a -> Constant e b # FunctorWithIndex r ((->) r :: Type -> Type) Instance detailsDefined in WithIndex Methodsimap :: (r -> a -> b) -> (r -> a) -> r -> b # FunctorWithIndex Void (K1 i c :: Type -> Type) Instance detailsDefined in WithIndex Methodsimap :: (Void -> a -> b) -> K1 i c a -> K1 i c b # Instance detailsDefined in WithIndex Methodsimap :: ([Int] -> a -> b) -> Tree a -> Tree b # FunctorWithIndex i m => FunctorWithIndex (e, i) (ReaderT e m) Instance detailsDefined in WithIndex Methodsimap :: ((e, i) -> a -> b) -> ReaderT e m a -> ReaderT e m b # (FunctorWithIndex i f, FunctorWithIndex j g) => FunctorWithIndex (Either i j) (Sum f g) Instance detailsDefined in WithIndex Methodsimap :: (Either i j -> a -> b) -> Sum f g a -> Sum f g b # (FunctorWithIndex i f, FunctorWithIndex j g) => FunctorWithIndex (Either i j) (Product f g) Instance detailsDefined in WithIndex Methodsimap :: (Either i j -> a -> b) -> Product f g a -> Product f g b # (FunctorWithIndex i f, FunctorWithIndex j g) => FunctorWithIndex (Either i j) (f :+: g) Instance detailsDefined in WithIndex Methodsimap :: (Either i j -> a -> b) -> (f :+: g) a -> (f :+: g) b # (FunctorWithIndex i f, FunctorWithIndex j g) => FunctorWithIndex (Either i j) (f :*: g) Instance detailsDefined in WithIndex Methodsimap :: (Either i j -> a -> b) -> (f :*: g) a -> (f :*: g) b # (FunctorWithIndex i f, FunctorWithIndex j g) => FunctorWithIndex (i, j) (Compose f g) Instance detailsDefined in WithIndex Methodsimap :: ((i, j) -> a -> b) -> Compose f g a -> Compose f g b # (FunctorWithIndex i f, FunctorWithIndex j g) => FunctorWithIndex (i, j) (f :.: g) Instance detailsDefined in WithIndex Methodsimap :: ((i, j) -> a -> b) -> (f :.: g) a -> (f :.: g) b # class Foldable f => FoldableWithIndex i (f :: Type -> Type) | f -> i where # A container that supports folding with an additional index. Minimal complete definition Nothing Methods ifoldMap :: Monoid m => (i -> a -> m) -> f a -> m # Fold a container by mapping value to an arbitrary Monoid with access to the index i. When you don't need access to the index then foldMap is more flexible in what it accepts. foldMap ≡ ifoldMap . const  ifoldMap' :: Monoid m => (i -> a -> m) -> f a -> m # A variant of ifoldMap that is strict in the accumulator. When you don't need access to the index then foldMap' is more flexible in what it accepts. foldMap' ≡ ifoldMap' . const  ifoldr :: (i -> a -> b -> b) -> b -> f a -> b # Right-associative fold of an indexed container with access to the index i. When you don't need access to the index then foldr is more flexible in what it accepts. foldr ≡ ifoldr . const  ifoldl :: (i -> b -> a -> b) -> b -> f a -> b # Left-associative fold of an indexed container with access to the index i. When you don't need access to the index then foldl is more flexible in what it accepts. foldl ≡ ifoldl . const  ifoldr' :: (i -> a -> b -> b) -> b -> f a -> b # Strictly fold right over the elements of a structure with access to the index i. When you don't need access to the index then foldr' is more flexible in what it accepts. foldr' ≡ ifoldr' . const  ifoldl' :: (i -> b -> a -> b) -> b -> f a -> b # Fold over the elements of a structure with an index, associating to the left, but strictly. When you don't need access to the index then foldlOf' is more flexible in what it accepts. foldl' l ≡ ifoldl' l . const  #### Instances Instances details  Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Int -> a -> m) -> [a] -> m #ifoldMap' :: Monoid m => (Int -> a -> m) -> [a] -> m #ifoldr :: (Int -> a -> b -> b) -> b -> [a] -> b #ifoldl :: (Int -> b -> a -> b) -> b -> [a] -> b #ifoldr' :: (Int -> a -> b -> b) -> b -> [a] -> b #ifoldl' :: (Int -> b -> a -> b) -> b -> [a] -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Int -> a -> m) -> ZipList a -> m #ifoldMap' :: Monoid m => (Int -> a -> m) -> ZipList a -> m #ifoldr :: (Int -> a -> b -> b) -> b -> ZipList a -> b #ifoldl :: (Int -> b -> a -> b) -> b -> ZipList a -> b #ifoldr' :: (Int -> a -> b -> b) -> b -> ZipList a -> b #ifoldl' :: (Int -> b -> a -> b) -> b -> ZipList a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Int -> a -> m) -> NonEmpty a -> m #ifoldMap' :: Monoid m => (Int -> a -> m) -> NonEmpty a -> m #ifoldr :: (Int -> a -> b -> b) -> b -> NonEmpty a -> b #ifoldl :: (Int -> b -> a -> b) -> b -> NonEmpty a -> b #ifoldr' :: (Int -> a -> b -> b) -> b -> NonEmpty a -> b #ifoldl' :: (Int -> b -> a -> b) -> b -> NonEmpty a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Int -> a -> m) -> IntMap a -> m #ifoldMap' :: Monoid m => (Int -> a -> m) -> IntMap a -> m #ifoldr :: (Int -> a -> b -> b) -> b -> IntMap a -> b #ifoldl :: (Int -> b -> a -> b) -> b -> IntMap a -> b #ifoldr' :: (Int -> a -> b -> b) -> b -> IntMap a -> b #ifoldl' :: (Int -> b -> a -> b) -> b -> IntMap a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Int -> a -> m) -> Seq a -> m #ifoldMap' :: Monoid m => (Int -> a -> m) -> Seq a -> m #ifoldr :: (Int -> a -> b -> b) -> b -> Seq a -> b #ifoldl :: (Int -> b -> a -> b) -> b -> Seq a -> b #ifoldr' :: (Int -> a -> b -> b) -> b -> Seq a -> b #ifoldl' :: (Int -> b -> a -> b) -> b -> Seq a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (() -> a -> m) -> Maybe a -> m #ifoldMap' :: Monoid m => (() -> a -> m) -> Maybe a -> m #ifoldr :: (() -> a -> b -> b) -> b -> Maybe a -> b #ifoldl :: (() -> b -> a -> b) -> b -> Maybe a -> b #ifoldr' :: (() -> a -> b -> b) -> b -> Maybe a -> b #ifoldl' :: (() -> b -> a -> b) -> b -> Maybe a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (() -> a -> m) -> Par1 a -> m #ifoldMap' :: Monoid m => (() -> a -> m) -> Par1 a -> m #ifoldr :: (() -> a -> b -> b) -> b -> Par1 a -> b #ifoldl :: (() -> b -> a -> b) -> b -> Par1 a -> b #ifoldr' :: (() -> a -> b -> b) -> b -> Par1 a -> b #ifoldl' :: (() -> b -> a -> b) -> b -> Par1 a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (() -> a -> m) -> Identity a -> m #ifoldMap' :: Monoid m => (() -> a -> m) -> Identity a -> m #ifoldr :: (() -> a -> b -> b) -> b -> Identity a -> b #ifoldl :: (() -> b -> a -> b) -> b -> Identity a -> b #ifoldr' :: (() -> a -> b -> b) -> b -> Identity a -> b #ifoldl' :: (() -> b -> a -> b) -> b -> Identity a -> b # FoldableWithIndex k (Map k) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (k -> a -> m) -> Map k a -> m #ifoldMap' :: Monoid m => (k -> a -> m) -> Map k a -> m #ifoldr :: (k -> a -> b -> b) -> b -> Map k a -> b #ifoldl :: (k -> b -> a -> b) -> b -> Map k a -> b #ifoldr' :: (k -> a -> b -> b) -> b -> Map k a -> b #ifoldl' :: (k -> b -> a -> b) -> b -> Map k a -> b # FoldableWithIndex k ((,) k) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (k -> a -> m) -> (k, a) -> m #ifoldMap' :: Monoid m => (k -> a -> m) -> (k, a) -> m #ifoldr :: (k -> a -> b -> b) -> b -> (k, a) -> b #ifoldl :: (k -> b -> a -> b) -> b -> (k, a) -> b #ifoldr' :: (k -> a -> b -> b) -> b -> (k, a) -> b #ifoldl' :: (k -> b -> a -> b) -> b -> (k, a) -> b # Ix i => FoldableWithIndex i (Array i) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (i -> a -> m) -> Array i a -> m #ifoldMap' :: Monoid m => (i -> a -> m) -> Array i a -> m #ifoldr :: (i -> a -> b -> b) -> b -> Array i a -> b #ifoldl :: (i -> b -> a -> b) -> b -> Array i a -> b #ifoldr' :: (i -> a -> b -> b) -> b -> Array i a -> b #ifoldl' :: (i -> b -> a -> b) -> b -> Array i a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Void -> a -> m) -> V1 a -> m #ifoldMap' :: Monoid m => (Void -> a -> m) -> V1 a -> m #ifoldr :: (Void -> a -> b -> b) -> b -> V1 a -> b #ifoldl :: (Void -> b -> a -> b) -> b -> V1 a -> b #ifoldr' :: (Void -> a -> b -> b) -> b -> V1 a -> b #ifoldl' :: (Void -> b -> a -> b) -> b -> V1 a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Void -> a -> m) -> U1 a -> m #ifoldMap' :: Monoid m => (Void -> a -> m) -> U1 a -> m #ifoldr :: (Void -> a -> b -> b) -> b -> U1 a -> b #ifoldl :: (Void -> b -> a -> b) -> b -> U1 a -> b #ifoldr' :: (Void -> a -> b -> b) -> b -> U1 a -> b #ifoldl' :: (Void -> b -> a -> b) -> b -> U1 a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Void -> a -> m) -> Proxy a -> m #ifoldMap' :: Monoid m => (Void -> a -> m) -> Proxy a -> m #ifoldr :: (Void -> a -> b -> b) -> b -> Proxy a -> b #ifoldl :: (Void -> b -> a -> b) -> b -> Proxy a -> b #ifoldr' :: (Void -> a -> b -> b) -> b -> Proxy a -> b #ifoldl' :: (Void -> b -> a -> b) -> b -> Proxy a -> b # FoldableWithIndex i f => FoldableWithIndex i (Reverse f) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (i -> a -> m) -> Reverse f a -> m #ifoldMap' :: Monoid m => (i -> a -> m) -> Reverse f a -> m #ifoldr :: (i -> a -> b -> b) -> b -> Reverse f a -> b #ifoldl :: (i -> b -> a -> b) -> b -> Reverse f a -> b #ifoldr' :: (i -> a -> b -> b) -> b -> Reverse f a -> b #ifoldl' :: (i -> b -> a -> b) -> b -> Reverse f a -> b # FoldableWithIndex i f => FoldableWithIndex i (Rec1 f) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (i -> a -> m) -> Rec1 f a -> m #ifoldMap' :: Monoid m => (i -> a -> m) -> Rec1 f a -> m #ifoldr :: (i -> a -> b -> b) -> b -> Rec1 f a -> b #ifoldl :: (i -> b -> a -> b) -> b -> Rec1 f a -> b #ifoldr' :: (i -> a -> b -> b) -> b -> Rec1 f a -> b #ifoldl' :: (i -> b -> a -> b) -> b -> Rec1 f a -> b # FoldableWithIndex i m => FoldableWithIndex i (IdentityT m) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m0 => (i -> a -> m0) -> IdentityT m a -> m0 #ifoldMap' :: Monoid m0 => (i -> a -> m0) -> IdentityT m a -> m0 #ifoldr :: (i -> a -> b -> b) -> b -> IdentityT m a -> b #ifoldl :: (i -> b -> a -> b) -> b -> IdentityT m a -> b #ifoldr' :: (i -> a -> b -> b) -> b -> IdentityT m a -> b #ifoldl' :: (i -> b -> a -> b) -> b -> IdentityT m a -> b # FoldableWithIndex i f => FoldableWithIndex i (Backwards f) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (i -> a -> m) -> Backwards f a -> m #ifoldMap' :: Monoid m => (i -> a -> m) -> Backwards f a -> m #ifoldr :: (i -> a -> b -> b) -> b -> Backwards f a -> b #ifoldl :: (i -> b -> a -> b) -> b -> Backwards f a -> b #ifoldr' :: (i -> a -> b -> b) -> b -> Backwards f a -> b #ifoldl' :: (i -> b -> a -> b) -> b -> Backwards f a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Void -> a -> m) -> Const e a -> m #ifoldMap' :: Monoid m => (Void -> a -> m) -> Const e a -> m #ifoldr :: (Void -> a -> b -> b) -> b -> Const e a -> b #ifoldl :: (Void -> b -> a -> b) -> b -> Const e a -> b #ifoldr' :: (Void -> a -> b -> b) -> b -> Const e a -> b #ifoldl' :: (Void -> b -> a -> b) -> b -> Const e a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Void -> a -> m) -> Constant e a -> m #ifoldMap' :: Monoid m => (Void -> a -> m) -> Constant e a -> m #ifoldr :: (Void -> a -> b -> b) -> b -> Constant e a -> b #ifoldl :: (Void -> b -> a -> b) -> b -> Constant e a -> b #ifoldr' :: (Void -> a -> b -> b) -> b -> Constant e a -> b #ifoldl' :: (Void -> b -> a -> b) -> b -> Constant e a -> b # FoldableWithIndex Void (K1 i c :: Type -> Type) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Void -> a -> m) -> K1 i c a -> m #ifoldMap' :: Monoid m => (Void -> a -> m) -> K1 i c a -> m #ifoldr :: (Void -> a -> b -> b) -> b -> K1 i c a -> b #ifoldl :: (Void -> b -> a -> b) -> b -> K1 i c a -> b #ifoldr' :: (Void -> a -> b -> b) -> b -> K1 i c a -> b #ifoldl' :: (Void -> b -> a -> b) -> b -> K1 i c a -> b # Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => ([Int] -> a -> m) -> Tree a -> m #ifoldMap' :: Monoid m => ([Int] -> a -> m) -> Tree a -> m #ifoldr :: ([Int] -> a -> b -> b) -> b -> Tree a -> b #ifoldl :: ([Int] -> b -> a -> b) -> b -> Tree a -> b #ifoldr' :: ([Int] -> a -> b -> b) -> b -> Tree a -> b #ifoldl' :: ([Int] -> b -> a -> b) -> b -> Tree a -> b # (FoldableWithIndex i f, FoldableWithIndex j g) => FoldableWithIndex (Either i j) (Sum f g) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Either i j -> a -> m) -> Sum f g a -> m #ifoldMap' :: Monoid m => (Either i j -> a -> m) -> Sum f g a -> m #ifoldr :: (Either i j -> a -> b -> b) -> b -> Sum f g a -> b #ifoldl :: (Either i j -> b -> a -> b) -> b -> Sum f g a -> b #ifoldr' :: (Either i j -> a -> b -> b) -> b -> Sum f g a -> b #ifoldl' :: (Either i j -> b -> a -> b) -> b -> Sum f g a -> b # (FoldableWithIndex i f, FoldableWithIndex j g) => FoldableWithIndex (Either i j) (Product f g) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Either i j -> a -> m) -> Product f g a -> m #ifoldMap' :: Monoid m => (Either i j -> a -> m) -> Product f g a -> m #ifoldr :: (Either i j -> a -> b -> b) -> b -> Product f g a -> b #ifoldl :: (Either i j -> b -> a -> b) -> b -> Product f g a -> b #ifoldr' :: (Either i j -> a -> b -> b) -> b -> Product f g a -> b #ifoldl' :: (Either i j -> b -> a -> b) -> b -> Product f g a -> b # (FoldableWithIndex i f, FoldableWithIndex j g) => FoldableWithIndex (Either i j) (f :+: g) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Either i j -> a -> m) -> (f :+: g) a -> m #ifoldMap' :: Monoid m => (Either i j -> a -> m) -> (f :+: g) a -> m #ifoldr :: (Either i j -> a -> b -> b) -> b -> (f :+: g) a -> b #ifoldl :: (Either i j -> b -> a -> b) -> b -> (f :+: g) a -> b #ifoldr' :: (Either i j -> a -> b -> b) -> b -> (f :+: g) a -> b #ifoldl' :: (Either i j -> b -> a -> b) -> b -> (f :+: g) a -> b # (FoldableWithIndex i f, FoldableWithIndex j g) => FoldableWithIndex (Either i j) (f :*: g) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => (Either i j -> a -> m) -> (f :*: g) a -> m #ifoldMap' :: Monoid m => (Either i j -> a -> m) -> (f :*: g) a -> m #ifoldr :: (Either i j -> a -> b -> b) -> b -> (f :*: g) a -> b #ifoldl :: (Either i j -> b -> a -> b) -> b -> (f :*: g) a -> b #ifoldr' :: (Either i j -> a -> b -> b) -> b -> (f :*: g) a -> b #ifoldl' :: (Either i j -> b -> a -> b) -> b -> (f :*: g) a -> b # (FoldableWithIndex i f, FoldableWithIndex j g) => FoldableWithIndex (i, j) (Compose f g) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => ((i, j) -> a -> m) -> Compose f g a -> m #ifoldMap' :: Monoid m => ((i, j) -> a -> m) -> Compose f g a -> m #ifoldr :: ((i, j) -> a -> b -> b) -> b -> Compose f g a -> b #ifoldl :: ((i, j) -> b -> a -> b) -> b -> Compose f g a -> b #ifoldr' :: ((i, j) -> a -> b -> b) -> b -> Compose f g a -> b #ifoldl' :: ((i, j) -> b -> a -> b) -> b -> Compose f g a -> b # (FoldableWithIndex i f, FoldableWithIndex j g) => FoldableWithIndex (i, j) (f :.: g) Instance detailsDefined in WithIndex MethodsifoldMap :: Monoid m => ((i, j) -> a -> m) -> (f :.: g) a -> m #ifoldMap' :: Monoid m => ((i, j) -> a -> m) -> (f :.: g) a -> m #ifoldr :: ((i, j) -> a -> b -> b) -> b -> (f :.: g) a -> b #ifoldl :: ((i, j) -> b -> a -> b) -> b -> (f :.: g) a -> b #ifoldr' :: ((i, j) -> a -> b -> b) -> b -> (f :.: g) a -> b #ifoldl' :: ((i, j) -> b -> a -> b) -> b -> (f :.: g) a -> b # class (FunctorWithIndex i t, FoldableWithIndex i t, Traversable t) => TraversableWithIndex i (t :: Type -> Type) | t -> i where # A Traversable with an additional index. An instance must satisfy a (modified) form of the Traversable laws: itraverse (const Identity) ≡ Identity fmap (itraverse f) . itraverse g ≡ getCompose . itraverse (\i -> Compose . fmap (f i) . g i)  Minimal complete definition Nothing Methods itraverse :: Applicative f => (i -> a -> f b) -> t a -> f (t b) # Traverse an indexed container. itraverse ≡ itraverseOf itraversed  #### Instances Instances details  Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Int -> a -> f b) -> [a] -> f [b] # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Int -> a -> f b) -> ZipList a -> f (ZipList b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Int -> a -> f b) -> NonEmpty a -> f (NonEmpty b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Int -> a -> f b) -> IntMap a -> f (IntMap b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Int -> a -> f b) -> Seq a -> f (Seq b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (() -> a -> f b) -> Maybe a -> f (Maybe b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (() -> a -> f b) -> Par1 a -> f (Par1 b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (() -> a -> f b) -> Identity a -> f (Identity b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (k -> a -> f b) -> Map k a -> f (Map k b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (k -> a -> f b) -> (k, a) -> f (k, b) # Ix i => TraversableWithIndex i (Array i) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (i -> a -> f b) -> Array i a -> f (Array i b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Void -> a -> f b) -> V1 a -> f (V1 b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Void -> a -> f b) -> U1 a -> f (U1 b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Void -> a -> f b) -> Proxy a -> f (Proxy b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => (i -> a -> f0 b) -> Reverse f a -> f0 (Reverse f b) # TraversableWithIndex i f => TraversableWithIndex i (Rec1 f) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => (i -> a -> f0 b) -> Rec1 f a -> f0 (Rec1 f b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (i -> a -> f b) -> IdentityT m a -> f (IdentityT m b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => (i -> a -> f0 b) -> Backwards f a -> f0 (Backwards f b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Void -> a -> f b) -> Const e a -> f (Const e b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Void -> a -> f b) -> Constant e a -> f (Constant e b) # TraversableWithIndex Void (K1 i c :: Type -> Type) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => (Void -> a -> f b) -> K1 i c a -> f (K1 i c b) # Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f => ([Int] -> a -> f b) -> Tree a -> f (Tree b) # (TraversableWithIndex i f, TraversableWithIndex j g) => TraversableWithIndex (Either i j) (Sum f g) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => (Either i j -> a -> f0 b) -> Sum f g a -> f0 (Sum f g b) # (TraversableWithIndex i f, TraversableWithIndex j g) => TraversableWithIndex (Either i j) (Product f g) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => (Either i j -> a -> f0 b) -> Product f g a -> f0 (Product f g b) # (TraversableWithIndex i f, TraversableWithIndex j g) => TraversableWithIndex (Either i j) (f :+: g) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => (Either i j -> a -> f0 b) -> (f :+: g) a -> f0 ((f :+: g) b) # (TraversableWithIndex i f, TraversableWithIndex j g) => TraversableWithIndex (Either i j) (f :*: g) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => (Either i j -> a -> f0 b) -> (f :*: g) a -> f0 ((f :*: g) b) # (TraversableWithIndex i f, TraversableWithIndex j g) => TraversableWithIndex (i, j) (Compose f g) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => ((i, j) -> a -> f0 b) -> Compose f g a -> f0 (Compose f g b) # (TraversableWithIndex i f, TraversableWithIndex j g) => TraversableWithIndex (i, j) (f :.: g) Instance detailsDefined in WithIndex Methodsitraverse :: Applicative f0 => ((i, j) -> a -> f0 b) -> (f :.: g) a -> f0 ((f :.: g) b) # Arguments  :: Name Type constructor name -> DecsQ Generate a Prism for each constructor of a data type. Isos generated when possible. Reviews are created for constructors with existentially quantified constructors and GADTs. e.g. data FooBarBaz a = Foo Int | Bar a | Baz Int Char makePrisms ''FooBarBaz  will create _Foo :: Prism' (FooBarBaz a) Int _Bar :: Prism (FooBarBaz a) (FooBarBaz b) a b _Baz :: Prism' (FooBarBaz a) (Int, Char)  Arguments  :: Name Type constructor name -> DecsQ Generate a Prism for each constructor of a data type and combine them into a single class. No Isos are created. Reviews are created for constructors with existentially quantified constructors and GADTs. e.g. data FooBarBaz a = Foo Int | Bar a | Baz Int Char makeClassyPrisms ''FooBarBaz  will create class AsFooBarBaz s a | s -> a where _FooBarBaz :: Prism' s (FooBarBaz a) _Foo :: Prism' s Int _Bar :: Prism' s a _Baz :: Prism' s (Int,Char) _Foo = _FooBarBaz % _Foo _Bar = _FooBarBaz % _Bar _Baz = _FooBarBaz % _Baz instance AsFooBarBaz (FooBarBaz a) a  Generate an As class of prisms. Names are selected by prefixing the constructor name with an underscore. Constructors with multiple fields will construct Prisms to tuples of those fields. type ClassyNamer # Arguments  = Name Name of the data type that lenses are being generated for. -> Maybe (Name, Name) Names of the class and the main method it generates, respectively. The optional rule to create a class and method around a monomorphic data type. If this naming convention is provided, it generates a "classy" lens. data DefName # Name to give to generated field optics. Constructors  TopName Name Simple top-level definition name MethodName Name Name makeFields-style class name and method name #### Instances Instances details  Instance detailsDefined in Optics.TH.Internal.Product Methods(==) :: DefName -> DefName -> Bool #(/=) :: DefName -> DefName -> Bool # Instance detailsDefined in Optics.TH.Internal.Product Methods(<) :: DefName -> DefName -> Bool #(<=) :: DefName -> DefName -> Bool #(>) :: DefName -> DefName -> Bool #(>=) :: DefName -> DefName -> Bool # Instance detailsDefined in Optics.TH.Internal.Product MethodsshowList :: [DefName] -> ShowS # type FieldNamer # Arguments  = Name Name of the data type that lenses are being generated for. -> [Name] Names of all fields (including the field being named) in the data type. -> Name Name of the field being named. -> [DefName] Name(s) of the lens functions. If empty, no lens is created for that field. The rule to create function names of lenses for data fields. Although it's sometimes useful, you won't need the first two arguments most of the time. data LensRules # Rules to construct lenses for data fields. Build field optics as labels with a custom configuration. Build field optics as instances of the LabelOptic class for use with overloaded labels. See Optics.Label for how to use this pattern. e.g. data Animal = Cat { animalAge :: Int , animalName :: String } | Dog { animalAge :: Int , animalAbsurd :: forall a b. a -> b } makeFieldLabels ''Animal  will create instance (k ~ A_Lens, a ~ Int, b ~ Int ) => LabelOptic "age" k Animal Animal a b where labelOptic = lensVL$ \f s -> case s of
Cat x1 x2 -> fmap (\y -> Cat y x2) (f x1)
Dog x1 x2 -> fmap (\y -> Dog y x2) (f x1)

instance
(k ~ An_AffineTraversal, a ~ String, b ~ String
) => LabelOptic "name" k Animal Animal a b where
labelOptic = atraversalVL $\point f s -> case s of Cat x1 x2 -> fmap (\y -> Cat x1 y) (f x2) Dog x1 x2 -> point (Dog x1 x2) instance ( Dysfunctional "absurd" k Animal Animal a b , k ~ An_AffineFold, a ~ (x -> y), b ~ (x -> y) ) => LabelOptic "absurd" k Animal Animal a b where labelOptic = afolding$ \s -> case s of
Cat _ _  -> Nothing
Dog _ f  -> Just f


which can be used as #age, #name and #absurd with the OverloadedLabels language extension.

Note: if you wonder about the structure of instances, see Optics.Label.

makeFieldOptics = makeFieldLabelsWith fieldLabelsRules


An alias for makeFieldLabels noPrefixFieldLabels.

makeFieldLabelsFor :: [(String, String)] -> Name -> DecsQ #

Derive field optics as labels, specifying explicit pairings of (fieldName, labelName).

If you map multiple fields to the same label and it is present in the same constructor, Traversal (or Fold for a read only version) will be generated.

e.g.

makeFieldLabelsFor [("_foo", "fooLens"), ("baz", "lbaz")] ''Foo
makeFieldLabelsFor [("_barX", "bar"), ("_barY", "bar")] ''Bar


Make field optics as labels for all records in the given declaration quote. All record syntax in the input will be stripped off.

e.g.

declareLenses [d|
data Dog = Dog { name :: String, age :: Int }
deriving Show
|]


will create

data Dog = Dog String Int
deriving Show
instance (k ~ A_Lens, ...) => LabelOptic "name" k Dog Dog ...
instance (k ~ A_Lens, ...) => LabelOptic "age" k Dog Dog ...


declareFieldLabelsFor :: [(String, String)] -> DecsQ -> DecsQ #

Similar to makeFieldLabelsFor, but takes a declaration quote.

Rules for generation of LabelOptic instances for use with OverloadedLabels. Same as lensRules, but uses camelCaseNamer.

Note: if you don't want to prefix field names with the full name of the data type, you can use abbreviatedNamer instead.

Arguments

 :: [(String, String)] (Field name, Label name) -> LensRules

Construct a LensRules value for generating LabelOptic instances using the given map from field names to definition names.

Build field optics as top level functions with a sensible default configuration.

e.g.

data Animal
= Cat { _age  :: Int
, _name :: String
}
| Dog { _age    :: Int
, _absurd :: forall a b. a -> b
}
makeLenses ''Animal


will create

absurd :: forall a b. AffineFold Animal (a -> b)
absurd = afolding $\s -> case s of Cat _ _ -> Nothing Dog _ x -> Just x age :: Lens' Animal Int age = lensVL$ \f s -> case s of
Cat x1 x2 -> fmap (\y -> Cat y x2) (f x1)
Dog x1 x2 -> fmap (\y -> Dog y x2) (f x1)

name :: AffineTraversal' Animal String
name = atraversalVL $\point f s -> case s of Cat x1 x2 -> fmap (\y -> Cat x1 y) (f x2) Dog x1 x2 -> point (Dog x1 x2)  makeLenses = makeLensesWith lensRules  makeLensesFor :: [(String, String)] -> Name -> DecsQ # Derive field optics, specifying explicit pairings of (fieldName, opticName). If you map multiple fields to the same optic and it is present in the same constructor, Traversal (or Fold for a read only version) will be generated. e.g. makeLensesFor [("_foo", "fooLens"), ("baz", "lbaz")] ''Foo makeLensesFor [("_barX", "bar"), ("_barY", "bar")] ''Bar  Build field optics with a custom configuration. Make field optics for all records in the given declaration quote. All record syntax in the input will be stripped off. e.g. declareLenses [d| data Foo = Foo { fooX, fooY :: Int } deriving Show |]  will create data Foo = Foo Int Int deriving Show fooX, fooY :: Lens' Foo Int  declareLensesFor :: [(String, String)] -> DecsQ -> DecsQ # Similar to makeLensesFor, but takes a declaration quote. declareLenses with custom LensRules. Rules for making read-write field optics as top-level functions. It uses underscoreNoPrefixNamer. Arguments  :: [(String, String)] (Field name, Optic name) -> LensRules Construct a LensRules value for generating top-level functions using the given map from field names to definition names. Make lenses and traversals for a type, and create a class when the type has no arguments. e.g. data Foo = Foo { _fooX, _fooY :: Int } makeClassy ''Foo  will create class HasFoo c where foo :: Lens' c Foo fooX :: Lens' c Int fooY :: Lens' c Int fooX = foo % fooX fooY = foo % fooY instance HasFoo Foo where foo = lensVL id fooX = lensVL$ \f s -> case s of
Foo x1 x2 -> fmap (\y -> Foo y x2) (f x1)
fooY = lensVL $\f s -> case s of Foo x1 x2 -> fmap (\y -> Foo x1 y) (f x2)  makeClassy = makeLensesWith classyRules  Make lenses and traversals for a type, and create a class when the type has no arguments. Works the same as makeClassy except that (a) it expects that record field names do not begin with an underscore, (b) all record fields are made into lenses, and (c) the resulting lens is prefixed with an underscore. makeClassyFor :: String -> String -> [(String, String)] -> Name -> DecsQ # Derive lenses and traversals, using a named wrapper class, and specifying explicit pairings of (fieldName, traversalName). Example usage: makeClassyFor "HasFoo" "foo" [("_foo", "fooLens"), ("bar", "lbar")] ''Foo  For each record in the declaration quote, make lenses and traversals for it, and create a class when the type has no arguments. All record syntax in the input will be stripped off. e.g. declareClassy [d| data Foo = Foo { fooX, fooY :: Int } deriving Show |]  will create data Foo = Foo Int Int deriving Show class HasFoo t where foo :: Lens' t Foo instance HasFoo Foo where foo = id fooX, fooY :: HasFoo t => Lens' t Int  declareClassyFor :: [(String, (String, String))] -> [(String, String)] -> DecsQ -> DecsQ # Similar to makeClassyFor, but takes a declaration quote. Rules for making lenses and traversals that precompose another Lens. A LensRules used by makeClassy_. Arguments  :: (String -> Maybe (String, String)) Type Name -> Maybe (Class Name, Method Name) -> [(String, String)] (Field Name, Method Name) -> LensRules Rules for making lenses and traversals that precompose another Lens using a custom function for naming the class, main class method, and a mapping from field names to definition names. Generate overloaded field accessors. e.g data Foo a = Foo { _fooX :: Int, _fooY :: a } newtype Bar = Bar { _barX :: Char } makeFields ''Foo makeFields ''Bar  will create class HasX s a | s -> a where x :: Lens' s a instance HasX (Foo a) Int where x = lensVL$ \f s -> case s of
Foo x1 x2 -> fmap (\y -> Foo y x2) (f x1)

class HasY s a | s -> a where
y :: Lens' s a

instance HasY (Foo a) a where
y = lensVL $\f s -> case s of Foo x1 x2 -> fmap (\y -> Foo x1 y) (f x2) instance HasX Bar Char where x = lensVL$ \f s -> case s of
Bar x1 -> fmap (\y -> Bar y) (f x1)


For details, see camelCaseFields.

makeFields = makeLensesWith defaultFieldRules


Generate overloaded field accessors based on field names which are only prefixed with an underscore (e.g. _name), not additionally with the type name (e.g. _fooName).

This might be the desired behaviour in case the DuplicateRecordFields language extension is used in order to get rid of the necessity to prefix each field name with the type name.

As an example:

data Foo a  = Foo { _x :: Int, _y :: a }
newtype Bar = Bar { _x :: Char }
makeFieldsNoPrefix ''Foo
makeFieldsNoPrefix ''Bar


will create classes

class HasX s a | s -> a where
x :: Lens' s a
class HasY s a | s -> a where
y :: Lens' s a


together with instances

instance HasX (Foo a) Int
instance HasY (Foo a) a where
instance HasX Bar Char where


For details, see classUnderscoreNoPrefixFields.

makeFieldsNoPrefix = makeLensesWith classUnderscoreNoPrefixFields

 declareFields = declareLensesWith defaultFieldRules

Generate a Prism for each constructor of each data type.

e.g.

declarePrisms [d|
data Exp = Lit Int | Var String | Lambda{ bound::String, body::Exp }
|]


will create

data Exp = Lit Int | Var String | Lambda { bound::String, body::Exp }
_Lit :: Prism' Exp Int
_Var :: Prism' Exp String
_Lambda :: Prism' Exp (String, Exp)


Generate "simple" optics even when type-changing optics are possible. (e.g. Lens' instead of Lens)

Indicate whether or not to supply the signatures for the generated lenses.

Disabling this can be useful if you want to provide a more restricted type signature or if you want to supply hand-written haddocks.

Generate "updateable" optics when True. When False, (affine) folds will be generated instead of (affine) traversals and getters will be generated instead of lenses. This mode is intended to be used for types with invariants which must be maintained by "smart" constructors.

Generate optics using lazy pattern matches. This can allow fields of an undefined value to be initialized with lenses:

data Foo = Foo {_x :: Int, _y :: Bool}
deriving Show

makeLensesWith (lensRules & generateLazyPatterns .~ True) ''Foo

> undefined & x .~ 8 & y .~ True
Foo {_x = 8, _y = True}


The downside of this flag is that it can lead to space-leaks and code-size/compile-time increases when generated for large records. By default this flag is turned off, and strict optics are generated.

When using lazy optics the strict optic can be recovered by composing with equality':

strictOptic = equality' % lazyOptic


Create the class if the constructor if generated lenses would be type-preserving and the lensClass rule matches.

Lens' to access the convention for naming fields in our LensRules.

Lens' to access the option for naming "classy" lenses.

Field rules for fields without any prefix. Useful for generation of field labels when paired with DuplicateRecordFields language extension so that no prefixes for field names are necessary.

Since: optics-th-0.2

Field rules for fields in the form  _prefix_fieldname

Field rules for fields in the form  prefixFieldname or _prefixFieldname

If you want all fields to be lensed, then there is no reason to use an _ before the prefix. If any of the record fields leads with an _ then it is assume a field without an _ should not have a lens created.

Note: The prefix must be the same as the typename (with the first letter lowercased). This is a change from lens versions before lens 4.5. If you want the old behaviour, use makeLensesWith abbreviatedFields

Field rules for fields in the form  _fieldname  (the leading underscore is mandatory).

Note: The primary difference to camelCaseFields is that for classUnderscoreNoPrefixFields the field names are not expected to be prefixed with the type name. This might be the desired behaviour when the DuplicateRecordFields extension is enabled.

Field rules fields in the form  prefixFieldname or _prefixFieldname  If you want all fields to be lensed, then there is no reason to use an _ before the prefix. If any of the record fields leads with an _ then it is assume a field without an _ should not have a lens created.

Note that prefix may be any string of characters that are not uppercase letters. (In particular, it may be arbitrary string of lowercase letters and numbers) This is the behavior that defaultFieldRules had in lens 4.4 and earlier.

A FieldNamer that leaves the field name as-is. Useful for generation of field labels when paired with DuplicateRecordFields language extension so that no prefixes for field names are necessary.

Since: optics-th-0.2

A FieldNamer that strips the _ off of the field name, lowercases the name, and skips the field if it doesn't start with an '_'.

lookingupNamer :: [(String, String)] -> FieldNamer #

Create a FieldNamer from explicit pairings of (fieldName, lensName).

Arguments

 :: (String -> [String]) A function that maps a fieldName to lensNames. -> FieldNamer

Create a FieldNamer from a mapping function. If the function returns [], it creates no lens for the field.

A FieldNamer for underscoreFields.

A FieldNamer for camelCaseFields.

A FieldNamer for classUnderscoreNoPrefixFields.

A FieldNamer for abbreviatedFields.

class ViewableOptic k r #

Generalized view (even more powerful than view from the lens library).

View the value(s) pointed to by an optic.

The type of the result depends on the optic. You get:

• Exactly one result a with Iso, Lens, ReversedPrism and Getter.
• At most one result Maybe a with Prism, AffineTraversal and AffineFold.
• Monoidal summary of all results Monoid a => a with Traversal and Fold.

When in doubt, use specific, flavour restricted versions. This function is mostly useful for things such as passthrough.

Minimal complete definition

Associated Types

type ViewResult k r #

#### Instances

Instances details

type family ViewResult k r #

#### Instances

Instances details
 type ViewResult A_Fold r Instance detailsDefined in Optics.View type ViewResult A_Fold r = r Instance detailsDefined in Optics.View type ViewResult An_AffineFold r = Maybe r type ViewResult A_Getter r Instance detailsDefined in Optics.View type ViewResult A_Getter r = r Instance detailsDefined in Optics.View type ViewResult A_ReversedPrism r = r Instance detailsDefined in Optics.View type ViewResult A_Traversal r = r Instance detailsDefined in Optics.View type ViewResult A_Prism r Instance detailsDefined in Optics.View type ViewResult A_Prism r = Maybe r type ViewResult A_Lens r Instance detailsDefined in Optics.View type ViewResult A_Lens r = r type ViewResult An_Iso r Instance detailsDefined in Optics.View type ViewResult An_Iso r = r

class (MonadReader b m, MonadReader a n, Magnify m n b a) => MagnifyMany (m :: Type -> Type) (n :: Type -> Type) b a | m -> b, n -> a, m a -> n, n b -> m where #

Extends Magnify with an ability to magnify using a Fold over multiple targets so that actions for each one are executed sequentially and the results are aggregated.

There is however no sensible instance of MagnifyMany for StateT.

Methods

magnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> m c -> n c infixr 2 #

#### Instances

Instances details
 MagnifyMany m n b a => MagnifyMany (MaybeT m) (MaybeT n) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> MaybeT m c -> MaybeT n c # MagnifyMany m n b a => MagnifyMany (ListT m) (ListT n) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> ListT m c -> ListT n c # MagnifyMany m n b a => MagnifyMany (ExceptT e m) (ExceptT e n) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> ExceptT e m c -> ExceptT e n c # MagnifyMany m n b a => MagnifyMany (IdentityT m) (IdentityT n) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> IdentityT m c -> IdentityT n c # (Error e, MagnifyMany m n b a) => MagnifyMany (ErrorT e m) (ErrorT e n) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> ErrorT e m c -> ErrorT e n c # Monad m => MagnifyMany (ReaderT b m) (ReaderT a m) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> ReaderT b m c -> ReaderT a m c # (Monoid w, MagnifyMany m n b a) => MagnifyMany (WriterT w m) (WriterT w n) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> WriterT w m c -> WriterT w n c # (Monoid w, MagnifyMany m n b a) => MagnifyMany (WriterT w m) (WriterT w n) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> WriterT w m c -> WriterT w n c # MagnifyMany ((->) b :: Type -> Type) ((->) a :: Type -> Type) b a magnifyMany = foldMapOf  Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> (b -> c) -> a -> c # (Monad m, Monoid w) => MagnifyMany (RWST b w s m) (RWST a w s m) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> RWST b w s m c -> RWST a w s m c # (Monad m, Monoid w) => MagnifyMany (RWST b w s m) (RWST a w s m) b a Instance detailsDefined in Optics.Zoom MethodsmagnifyMany :: forall k c (is :: IxList). (Is k A_Fold, Monoid c) => Optic' k is a b -> RWST b w s m c -> RWST a w s m c #

class AppendIndices (xs :: IxList) (ys :: IxList) (ks :: IxList) | xs ys -> ks #

In pseudo (dependent-)Haskell, provide a witness

foldr f (foldr f init xs) ys = foldr f init (ys ++ xs)
where f = (->)


Since: optics-core-0.4

Minimal complete definition

appendIndices

#### Instances

Instances details
 AppendIndices xs ('[] :: [Type]) xs If the second list is empty, we can shortcircuit and pick the first list immediately. Instance detailsDefined in Optics.Internal.Optic.TypeLevel MethodsappendIndices :: IxEq i (Curry xs (Curry '[] i)) (Curry xs i) # AppendIndices ('[] :: [Type]) ys ys Instance detailsDefined in Optics.Internal.Optic.TypeLevel MethodsappendIndices :: IxEq i (Curry '[] (Curry ys i)) (Curry ys i) # AppendIndices xs ys ks => AppendIndices (x ': xs) ys (x ': ks) Instance detailsDefined in Optics.Internal.Optic.TypeLevel MethodsappendIndices :: IxEq i (Curry (x ': xs) (Curry ys i)) (Curry (x ': ks) i) #

class CurryCompose (xs :: IxList) where #

Class that is inhabited by all type-level lists xs, providing the ability to compose a function under Curry xs.

Methods

composeN :: (i -> j) -> Curry xs i -> Curry xs j #

Compose a function under Curry xs. This generalises (.) (aka fmap for (->)) to work for curried functions with one argument for each type in the list.

#### Instances

Instances details
 CurryCompose ('[] :: [Type]) Instance detailsDefined in Optics.Internal.Optic.TypeLevel MethodscomposeN :: (i -> j) -> Curry '[] i -> Curry '[] j # CurryCompose xs => CurryCompose (x ': xs) Instance detailsDefined in Optics.Internal.Optic.TypeLevel MethodscomposeN :: (i -> j) -> Curry (x ': xs) i -> Curry (x ': xs) j #

type family Curry (xs :: IxList) y where ... #

Curry a type-level list.

Curry xs y = foldr (->) y xs


Equations

 Curry ('[] :: [Type]) y = y Curry (x ': xs) y = x -> Curry xs y

type WithIx i = '[i] #

Singleton index list

type NoIx = '[] :: [Type] #

An alias for an empty index-list

type IxList = [Type] #

A list of index types, used for indexed optics.

Since: optics-core-0.2

data A_Review #

Tag for a review.

#### Instances

Instances details
 Instance detailsDefined in Optics.Re Associated Typestype ReversedOptic A_Review = (r :: Type) # Methodsre :: forall (is :: IxList) s t a b. AcceptsEmptyIndices "re" is => Optic A_Review is s t a b -> Optic (ReversedOptic A_Review) is b a t s # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_ReversedLens p => r) -> Constraints A_Review p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints A_Review p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_Review p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Review p, Constraints A_Review p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Review p, Constraints A_ReversedLens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Review p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Review p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedLens p, Constraints A_Review p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Review p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints A_Review p) => r) -> Constraints k p => r # (Functor f, f ~ g, s ~ t, a ~ b) => MappingOptic A_Review f g s t a b Instance detailsDefined in Optics.Mapping Associated Types Methodsmapping :: forall (is :: IxList). AcceptsEmptyIndices "mapping" is => Optic A_Review is s t a b -> Optic (MappedOptic A_Review) is (f s) (g t) (f a) (g b) # Instance detailsDefined in Optics.Re Instance detailsDefined in Optics.Mapping

data A_ReversedLens #

Tag for a reversed lens.

#### Instances

Instances details
 Instance detailsDefined in Optics.Re Associated Typestype ReversedOptic A_ReversedLens = (r :: Type) # Methodsre :: forall (is :: IxList) s t a b. AcceptsEmptyIndices "re" is => Optic A_ReversedLens is s t a b -> Optic (ReversedOptic A_ReversedLens) is b a t s # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_ReversedLens p => r) -> Constraints A_Review p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_ReversedLens p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Review p, Constraints A_ReversedLens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedLens p, Constraints A_Review p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedLens p, Constraints A_ReversedLens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedLens p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedLens p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_ReversedLens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints A_ReversedLens p) => r) -> Constraints k p => r # (Functor f, f ~ g, s ~ t, a ~ b) => MappingOptic A_ReversedLens f g s t a b Instance detailsDefined in Optics.Mapping Associated Types Methodsmapping :: forall (is :: IxList). AcceptsEmptyIndices "mapping" is => Optic A_ReversedLens is s t a b -> Optic (MappedOptic A_ReversedLens) is (f s) (g t) (f a) (g b) # Instance detailsDefined in Optics.Re Instance detailsDefined in Optics.Mapping

data A_Fold #

Tag for a fold.

#### Instances

Instances details
 Instance detailsDefined in Optics.View Associated Typestype ViewResult A_Fold r # Methodsgview :: forall s m (is :: IxList). MonadReader s m => Optic' A_Fold is s r -> m (ViewResult A_Fold r) #gviews :: forall s m (is :: IxList) a. MonadReader s m => Optic' A_Fold is s a -> (a -> r) -> m (ViewResult A_Fold r) # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineFold p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Getter p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_ReversedPrism p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Traversal p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineTraversal p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints A_Fold p) => r) -> Constraints k p => r # (s ~ t, a ~ b) => ToReadOnly A_Fold s t a b Instance detailsDefined in Optics.ReadOnly Associated Types Methodsgetting :: forall (is :: IxList). Optic A_Fold is s t a b -> Optic' (ReadOnlyOptic A_Fold) is s a # (s ~ t, a ~ b) => IxOptic A_Fold s t a b Instance detailsDefined in Optics.Indexed.Core MethodsnoIx :: forall (is :: IxList). NonEmptyIndices is => Optic A_Fold is s t a b -> Optic A_Fold NoIx s t a b # Instance detailsDefined in Optics.ReadOnly type ViewResult A_Fold r Instance detailsDefined in Optics.View type ViewResult A_Fold r = r

data An_AffineFold #

Tag for an affine fold.

#### Instances

Instances details
 Instance detailsDefined in Optics.View Associated Types Methodsgview :: forall s m (is :: IxList). MonadReader s m => Optic' An_AffineFold is s r -> m (ViewResult An_AffineFold r) #gviews :: forall s m (is :: IxList) a. MonadReader s m => Optic' An_AffineFold is s a -> (a -> r) -> m (ViewResult An_AffineFold r) # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineFold p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Getter p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_ReversedPrism p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineTraversal p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints An_AffineFold p) => r) -> Constraints k p => r # (s ~ t, a ~ b) => ToReadOnly An_AffineFold s t a b Instance detailsDefined in Optics.ReadOnly Associated Types Methodsgetting :: forall (is :: IxList). Optic An_AffineFold is s t a b -> Optic' (ReadOnlyOptic An_AffineFold) is s a # (s ~ t, a ~ b) => IxOptic An_AffineFold s t a b Instance detailsDefined in Optics.Indexed.Core MethodsnoIx :: forall (is :: IxList). NonEmptyIndices is => Optic An_AffineFold is s t a b -> Optic An_AffineFold NoIx s t a b # Instance detailsDefined in Optics.ReadOnly Instance detailsDefined in Optics.View type ViewResult An_AffineFold r = Maybe r

data A_Getter #

Tag for a getter.

#### Instances

Instances details
 Instance detailsDefined in Optics.Re Associated Typestype ReversedOptic A_Getter = (r :: Type) # Methodsre :: forall (is :: IxList) s t a b. AcceptsEmptyIndices "re" is => Optic A_Getter is s t a b -> Optic (ReversedOptic A_Getter) is b a t s # Instance detailsDefined in Optics.View Associated Typestype ViewResult A_Getter r # Methodsgview :: forall s m (is :: IxList). MonadReader s m => Optic' A_Getter is s r -> m (ViewResult A_Getter r) #gviews :: forall s m (is :: IxList) a. MonadReader s m => Optic' A_Getter is s a -> (a -> r) -> m (ViewResult A_Getter r) # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Getter p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Getter p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_ReversedPrism p => r) -> Constraints A_Getter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints A_Getter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_Getter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints A_Getter p) => r) -> Constraints k p => r # (s ~ t, a ~ b) => ToReadOnly A_Getter s t a b Instance detailsDefined in Optics.ReadOnly Associated Types Methodsgetting :: forall (is :: IxList). Optic A_Getter is s t a b -> Optic' (ReadOnlyOptic A_Getter) is s a # (s ~ t, a ~ b) => IxOptic A_Getter s t a b Instance detailsDefined in Optics.Indexed.Core MethodsnoIx :: forall (is :: IxList). NonEmptyIndices is => Optic A_Getter is s t a b -> Optic A_Getter NoIx s t a b # (Functor f, f ~ g, s ~ t, a ~ b) => MappingOptic A_Getter f g s t a b >>> [('a', True), ('b', False)] ^. _1 %& mapping "ab" >>> let v = [[ (('a', True), "foo"), (('b', False), "bar")], [ (('c', True), "xyz") ] ] >>> v ^. _1 % _2 %& mapping %& mapping [[True,False],[True]]  Instance detailsDefined in Optics.Mapping Associated Types Methodsmapping :: forall (is :: IxList). AcceptsEmptyIndices "mapping" is => Optic A_Getter is s t a b -> Optic (MappedOptic A_Getter) is (f s) (g t) (f a) (g b) # Instance detailsDefined in Optics.Re Instance detailsDefined in Optics.ReadOnly Instance detailsDefined in Optics.Mapping type ViewResult A_Getter r Instance detailsDefined in Optics.View type ViewResult A_Getter r = r

data A_ReversedPrism #

Tag for a reversed prism.

#### Instances

Instances details
 Instance detailsDefined in Optics.Re Associated Typestype ReversedOptic A_ReversedPrism = (r :: Type) # Methodsre :: forall (is :: IxList) s t a b. AcceptsEmptyIndices "re" is => Optic A_ReversedPrism is s t a b -> Optic (ReversedOptic A_ReversedPrism) is b a t s # Instance detailsDefined in Optics.View Associated Types Methodsgview :: forall s m (is :: IxList). MonadReader s m => Optic' A_ReversedPrism is s r -> m (ViewResult A_ReversedPrism r) #gviews :: forall s m (is :: IxList) a. MonadReader s m => Optic' A_ReversedPrism is s a -> (a -> r) -> m (ViewResult A_ReversedPrism r) # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_ReversedPrism p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_ReversedPrism p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_ReversedPrism p => r) -> Constraints A_Getter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_ReversedPrism p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # ToReadOnly A_ReversedPrism s t a b Instance detailsDefined in Optics.ReadOnly Associated Types Methodsgetting :: forall (is :: IxList). Optic A_ReversedPrism is s t a b -> Optic' (ReadOnlyOptic A_ReversedPrism) is s a # (Functor f, f ~ g, s ~ t, a ~ b) => MappingOptic A_ReversedPrism f g s t a b Instance detailsDefined in Optics.Mapping Associated Types Methodsmapping :: forall (is :: IxList). AcceptsEmptyIndices "mapping" is => Optic A_ReversedPrism is s t a b -> Optic (MappedOptic A_ReversedPrism) is (f s) (g t) (f a) (g b) # Instance detailsDefined in Optics.Re Instance detailsDefined in Optics.ReadOnly Instance detailsDefined in Optics.Mapping Instance detailsDefined in Optics.View type ViewResult A_ReversedPrism r = r

data A_Setter #

Tag for a setter.

#### Instances

Instances details
 Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Traversal p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineTraversal p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints A_Setter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Setter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Setter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Setter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints A_Setter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints A_Setter p) => r) -> Constraints k p => r # IxOptic A_Setter s t a b Instance detailsDefined in Optics.Indexed.Core MethodsnoIx :: forall (is :: IxList). NonEmptyIndices is => Optic A_Setter is s t a b -> Optic A_Setter NoIx s t a b #

data A_Traversal #

Tag for a traversal.

#### Instances

Instances details
 Instance detailsDefined in Optics.View Associated Types Methodsgview :: forall s m (is :: IxList). MonadReader s m => Optic' A_Traversal is s r -> m (ViewResult A_Traversal r) #gviews :: forall s m (is :: IxList) a. MonadReader s m => Optic' A_Traversal is s a -> (a -> r) -> m (ViewResult A_Traversal r) # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Traversal p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Traversal p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineTraversal p => r) -> Constraints A_Traversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints A_Traversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints A_Traversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_Traversal p => r # Instance detailsDefined in Optics.Passthrough Methodspassthrough :: forall (is :: IxList) s t a b. Optic A_Traversal is s t a b -> (a -> (r, b)) -> s -> (ViewResult A_Traversal r, t) # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Setter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints A_Traversal p) => r) -> Constraints k p => r # ToReadOnly A_Traversal s t a b Instance detailsDefined in Optics.ReadOnly Associated Types Methodsgetting :: forall (is :: IxList). Optic A_Traversal is s t a b -> Optic' (ReadOnlyOptic A_Traversal) is s a # IxOptic A_Traversal s t a b Instance detailsDefined in Optics.Indexed.Core MethodsnoIx :: forall (is :: IxList). NonEmptyIndices is => Optic A_Traversal is s t a b -> Optic A_Traversal NoIx s t a b # Instance detailsDefined in Optics.ReadOnly Instance detailsDefined in Optics.View type ViewResult A_Traversal r = r

Tag for an affine traversal.

#### Instances

Instances details
 Instance detailsDefined in Optics.View Associated Types Methodsgview :: forall s m (is :: IxList). MonadReader s m => Optic' An_AffineTraversal is s r -> m (ViewResult An_AffineTraversal r) #gviews :: forall s m (is :: IxList) a. MonadReader s m => Optic' An_AffineTraversal is s a -> (a -> r) -> m (ViewResult An_AffineTraversal r) # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineTraversal p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineTraversal p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineTraversal p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_AffineTraversal p => r) -> Constraints A_Traversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints An_AffineTraversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints An_AffineTraversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints An_AffineTraversal p => r # Instance detailsDefined in Optics.Passthrough Methodspassthrough :: forall (is :: IxList) s t a b. Optic An_AffineTraversal is s t a b -> (a -> (r, b)) -> s -> (ViewResult An_AffineTraversal r, t) # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Setter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # ToReadOnly An_AffineTraversal s t a b Instance detailsDefined in Optics.ReadOnly Associated Types Methodsgetting :: forall (is :: IxList). Optic An_AffineTraversal is s t a b -> Optic' (ReadOnlyOptic An_AffineTraversal) is s a # IxOptic An_AffineTraversal s t a b Instance detailsDefined in Optics.Indexed.Core MethodsnoIx :: forall (is :: IxList). NonEmptyIndices is => Optic An_AffineTraversal is s t a b -> Optic An_AffineTraversal NoIx s t a b # Instance detailsDefined in Optics.ReadOnly Instance detailsDefined in Optics.View

data A_Prism #

Tag for a prism.

#### Instances

Instances details
 Instance detailsDefined in Optics.Re Associated Typestype ReversedOptic A_Prism = (r :: Type) # Methodsre :: forall (is :: IxList) s t a b. AcceptsEmptyIndices "re" is => Optic A_Prism is s t a b -> Optic (ReversedOptic A_Prism) is b a t s # Instance detailsDefined in Optics.View Associated Typestype ViewResult A_Prism r # Methodsgview :: forall s m (is :: IxList). MonadReader s m => Optic' A_Prism is s r -> m (ViewResult A_Prism r) #gviews :: forall s m (is :: IxList) a. MonadReader s m => Optic' A_Prism is s a -> (a -> r) -> m (ViewResult A_Prism r) # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints A_Review p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints A_Traversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Prism p => r) -> Constraints An_AffineTraversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_Prism p => r # Instance detailsDefined in Optics.Passthrough Methodspassthrough :: forall (is :: IxList) s t a b. Optic A_Prism is s t a b -> (a -> (r, b)) -> s -> (ViewResult A_Prism r, t) # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Review p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedLens p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Review p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_ReversedLens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Getter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_ReversedPrism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Setter p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Traversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints An_AffineTraversal p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints An_Iso p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints A_Prism p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_Iso p, Constraints A_Prism p) => r) -> Constraints k p => r # ToReadOnly A_Prism s t a b Instance detailsDefined in Optics.ReadOnly Associated Types Methodsgetting :: forall (is :: IxList). Optic A_Prism is s t a b -> Optic' (ReadOnlyOptic A_Prism) is s a # (Functor f, f ~ g, s ~ t, a ~ b) => MappingOptic A_Prism f g s t a b Instance detailsDefined in Optics.Mapping Associated Types Methodsmapping :: forall (is :: IxList). AcceptsEmptyIndices "mapping" is => Optic A_Prism is s t a b -> Optic (MappedOptic A_Prism) is (f s) (g t) (f a) (g b) # (GConstructorImpl repDefined name s t a b, _name ~ AppendSymbol "_" name) => GenericOptic repDefined (_name :: Symbol) A_Prism s t a b Instance detailsDefined in Optics.Label MethodsgenericOptic :: Optic A_Prism NoIx s t a b Instance detailsDefined in Optics.Re Instance detailsDefined in Optics.ReadOnly Instance detailsDefined in Optics.Mapping type ViewResult A_Prism r Instance detailsDefined in Optics.View type ViewResult A_Prism r = Maybe r

data A_Lens #

Tag for a lens.

#### Instances

Instances details
 Instance detailsDefined in Optics.Re Associated Typestype ReversedOptic A_Lens = (r :: Type) # Methodsre :: forall (is :: IxList) s t a b. AcceptsEmptyIndices "re" is => Optic A_Lens is s t a b -> Optic (ReversedOptic A_Lens) is b a t s # Instance detailsDefined in Optics.View Associated Typestype ViewResult A_Lens r # Methodsgview :: forall s m (is :: IxList). MonadReader s m => Optic' A_Lens is s r -> m (ViewResult A_Lens r) #gviews :: forall s m (is :: IxList) a. MonadReader s m => Optic' A_Lens is s a -> (a -> r) -> m (ViewResult A_Lens r) # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints A_Fold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints An_AffineFold p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints A_Getter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints A_Setter p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints A_Traversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints A_Lens p => r) -> Constraints An_AffineTraversal p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping Methodsimplies :: forall (p :: Type -> Type -> Type -> Type) r. (Constraints An_Iso p => r) -> Constraints A_Lens p => r # Instance detailsDefined in Optics.Passthrough Methodspassthrough :: forall (is :: IxList) s t a b. Optic A_Lens is s t a b -> (a -> (r, b)) -> s -> (ViewResult A_Lens r, t) # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Fold p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineFold p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Getter p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_ReversedPrism p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Setter p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Traversal p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints An_AffineTraversal p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Prism p, Constraints A_Lens p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints A_Fold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints An_AffineFold p) => r) -> Constraints k p => r # Instance detailsDefined in Optics.Internal.Optic.Subtyping MethodsjoinKinds :: forall (p :: Type -> Type -> Type -> Type) r. ((Constraints A_Lens p, Constraints A_Getter p) => r) ->