mono-traversable-keys-0.2.0: Type-classes for interacting with monomorphic containers with a key
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.MonoTraversable.Keys

Description

Type-classes mirroring type-classes from Key, but working with monomorphic containers.

The motivation is that some commonly used data types (i.e., ByteString and Text) do not allow for instances of type-classes like Keyed, Indexable, and FoldableWithKey, since they are monomorphic structures. This module allows both monomorphic and polymorphic data types to be instances of the same type-classes.

All of the laws for the polymorphic type-classes apply to their monomorphic cousins.

Note that all type-classes have been prefixed with Mono, and functions have been prefixed with o. The mnemonic is inherited from MonoTraversable.

Synopsis

Documentation

type family MonoKey key Source #

Type family for getting the type of the key of a monomorphic container.

Instances

Instances details
type MonoKey ByteString Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey ByteString Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey IntSet Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey Text Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey Text Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (ZipList a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (ZipList a) = Int
type MonoKey (Identity a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Identity a) = ()
type MonoKey (IntMap a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (IntMap a) = Int
type MonoKey (Seq a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Seq a) = Int
type MonoKey (ViewL a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (ViewL a) = ()
type MonoKey (ViewR a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (ViewR a) = ()
type MonoKey (Set e) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Set e) = Int
type MonoKey (Tree a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Tree a) = Seq Int
type MonoKey (IO a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (IO a) = ()
type MonoKey (HashSet e) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (HashSet e) = Int
type MonoKey (Vector a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Vector a) = Int
type MonoKey (Vector a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Vector a) = Int
type MonoKey (Vector a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Vector a) = Int
type MonoKey (NonEmpty a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (NonEmpty a) = Int
type MonoKey (Maybe a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Maybe a) = ()
type MonoKey [a] Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey [a] = Int
type MonoKey (WrappedMonad m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (WrappedMonad m a) = ()
type MonoKey (Either a b) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Either a b) = ()
type MonoKey (Arg a b) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Arg a b) = ()
type MonoKey (Map k v) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Map k v) = k
type MonoKey (ListT m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (ListT m a) = Int
type MonoKey (MaybeT m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (MaybeT m a) = ()
type MonoKey (HashMap k v) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (HashMap k v) = k
type MonoKey (r -> a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (r -> a) = ()
type MonoKey (a, b) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (a, b) = ()
type MonoKey (WrappedArrow a b c) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (WrappedArrow a b c) = ()
type MonoKey (Const m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Const m a) = ()
type MonoKey (IdentityT m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (IdentityT m a) = ()
type MonoKey (ReaderT r m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (ReaderT r m a) = (r, Key m)
type MonoKey (StateT s m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (StateT s m a) = ()
type MonoKey (StateT s m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (StateT s m a) = ()
type MonoKey (WriterT w m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (WriterT w m a) = ()
type MonoKey (WriterT w m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (WriterT w m a) = ()
type MonoKey (Product f g a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Product f g a) = Either (Key f) (Key g)
type MonoKey (ContT r m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (ContT r m a) = ()
type MonoKey (Compose f g a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (Compose f g a) = (MonoKey (f a), MonoKey (g a))
type MonoKey (RWST r w s m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (RWST r w s m a) = ()
type MonoKey (RWST r w s m a) Source # 
Instance details

Defined in Data.MonoTraversable.Keys

type MonoKey (RWST r w s m a) = ()

Keyed Monomorphic Structures

class MonoFunctor mono => MonoKeyed mono where Source #

Monomorphic containers that can be mapped over.

Minimal complete definition

Nothing

Methods

omapWithKey :: (MonoKey mono -> Element mono -> Element mono) -> mono -> mono Source #

Map over a monomorphic container

default omapWithKey :: (Keyed f, Element (f a) ~ a, MonoKey (f a) ~ Key f, f a ~ mono) => (MonoKey mono -> Element mono -> Element mono) -> mono -> mono Source #

Instances

Instances details
MonoKeyed ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoKeyed ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoKeyed Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoKeyed Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoKeyed (ZipList a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (ZipList a) -> Element (ZipList a) -> Element (ZipList a)) -> ZipList a -> ZipList a Source #

MonoKeyed (Identity a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoKeyed (IntMap a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (IntMap a) -> Element (IntMap a) -> Element (IntMap a)) -> IntMap a -> IntMap a Source #

MonoKeyed (Seq a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Seq a) -> Element (Seq a) -> Element (Seq a)) -> Seq a -> Seq a Source #

MonoKeyed (ViewL a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (ViewL a) -> Element (ViewL a) -> Element (ViewL a)) -> ViewL a -> ViewL a Source #

MonoKeyed (ViewR a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (ViewR a) -> Element (ViewR a) -> Element (ViewR a)) -> ViewR a -> ViewR a Source #

MonoKeyed (Tree a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Tree a) -> Element (Tree a) -> Element (Tree a)) -> Tree a -> Tree a Source #

MonoKeyed (IO a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (IO a) -> Element (IO a) -> Element (IO a)) -> IO a -> IO a Source #

MonoKeyed (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a Source #

Storable a => MonoKeyed (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a Source #

Unbox a => MonoKeyed (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a Source #

MonoKeyed (NonEmpty a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoKeyed (Maybe a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Maybe a) -> Element (Maybe a) -> Element (Maybe a)) -> Maybe a -> Maybe a Source #

MonoKeyed [a] Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey [a] -> Element [a] -> Element [a]) -> [a] -> [a] Source #

Monad m => MonoKeyed (WrappedMonad m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoKeyed (Either a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Either a b) -> Element (Either a b) -> Element (Either a b)) -> Either a b -> Either a b Source #

MonoKeyed (Arg a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Arg a b) -> Element (Arg a b) -> Element (Arg a b)) -> Arg a b -> Arg a b Source #

MonoKeyed (Map k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Map k v) -> Element (Map k v) -> Element (Map k v)) -> Map k v -> Map k v Source #

Functor m => MonoKeyed (ListT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (ListT m a) -> Element (ListT m a) -> Element (ListT m a)) -> ListT m a -> ListT m a Source #

Functor m => MonoKeyed (MaybeT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (MaybeT m a) -> Element (MaybeT m a) -> Element (MaybeT m a)) -> MaybeT m a -> MaybeT m a Source #

MonoKeyed (HashMap k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (HashMap k v) -> Element (HashMap k v) -> Element (HashMap k v)) -> HashMap k v -> HashMap k v Source #

MonoKeyed (r -> a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (r -> a) -> Element (r -> a) -> Element (r -> a)) -> (r -> a) -> r -> a Source #

MonoKeyed (a, b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (a, b) -> Element (a, b) -> Element (a, b)) -> (a, b) -> (a, b) Source #

Arrow a => MonoKeyed (WrappedArrow a b c) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (WrappedArrow a b c) -> Element (WrappedArrow a b c) -> Element (WrappedArrow a b c)) -> WrappedArrow a b c -> WrappedArrow a b c Source #

MonoKeyed (Const m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Const m a) -> Element (Const m a) -> Element (Const m a)) -> Const m a -> Const m a Source #

Functor m => MonoKeyed (IdentityT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (IdentityT m a) -> Element (IdentityT m a) -> Element (IdentityT m a)) -> IdentityT m a -> IdentityT m a Source #

Keyed m => MonoKeyed (ReaderT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (ReaderT r m a) -> Element (ReaderT r m a) -> Element (ReaderT r m a)) -> ReaderT r m a -> ReaderT r m a Source #

Functor m => MonoKeyed (StateT s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (StateT s m a) -> Element (StateT s m a) -> Element (StateT s m a)) -> StateT s m a -> StateT s m a Source #

Functor m => MonoKeyed (StateT s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (StateT s m a) -> Element (StateT s m a) -> Element (StateT s m a)) -> StateT s m a -> StateT s m a Source #

Functor m => MonoKeyed (WriterT w m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (WriterT w m a) -> Element (WriterT w m a) -> Element (WriterT w m a)) -> WriterT w m a -> WriterT w m a Source #

Functor m => MonoKeyed (WriterT w m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (WriterT w m a) -> Element (WriterT w m a) -> Element (WriterT w m a)) -> WriterT w m a -> WriterT w m a Source #

(Keyed f, Keyed g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoKeyed (Product f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Product f g a) -> Element (Product f g a) -> Element (Product f g a)) -> Product f g a -> Product f g a Source #

Functor m => MonoKeyed (ContT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (ContT r m a) -> Element (ContT r m a) -> Element (ContT r m a)) -> ContT r m a -> ContT r m a Source #

(Keyed f, Keyed g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoKeyed (Compose f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (Compose f g a) -> Element (Compose f g a) -> Element (Compose f g a)) -> Compose f g a -> Compose f g a Source #

Functor m => MonoKeyed (RWST r w s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (RWST r w s m a) -> Element (RWST r w s m a) -> Element (RWST r w s m a)) -> RWST r w s m a -> RWST r w s m a Source #

Functor m => MonoKeyed (RWST r w s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

omapWithKey :: (MonoKey (RWST r w s m a) -> Element (RWST r w s m a) -> Element (RWST r w s m a)) -> RWST r w s m a -> RWST r w s m a Source #

class MonoFoldable mono => MonoFoldableWithKey mono where Source #

Monomorphic containers that can be folded over thier pairs of elements and corresponding keys.

Minimal complete definition

ofoldMapWithKey | ofoldlWithKey

Methods

otoKeyedList :: mono -> [(MonoKey mono, Element mono)] Source #

ofoldMapWithKey :: Monoid m => (MonoKey mono -> Element mono -> m) -> mono -> m Source #

ofoldrWithKey :: (MonoKey mono -> Element mono -> a -> a) -> a -> mono -> a Source #

ofoldlWithKey :: (a -> MonoKey mono -> Element mono -> a) -> a -> mono -> a Source #

Instances

Instances details
MonoFoldableWithKey ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoFoldableWithKey ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoFoldableWithKey IntSet Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoFoldableWithKey Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Text -> [(MonoKey Text, Element Text)] Source #

ofoldMapWithKey :: Monoid m => (MonoKey Text -> Element Text -> m) -> Text -> m Source #

ofoldrWithKey :: (MonoKey Text -> Element Text -> a -> a) -> a -> Text -> a Source #

ofoldlWithKey :: (a -> MonoKey Text -> Element Text -> a) -> a -> Text -> a Source #

MonoFoldableWithKey Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Text -> [(MonoKey Text, Element Text)] Source #

ofoldMapWithKey :: Monoid m => (MonoKey Text -> Element Text -> m) -> Text -> m Source #

ofoldrWithKey :: (MonoKey Text -> Element Text -> a -> a) -> a -> Text -> a Source #

ofoldlWithKey :: (a -> MonoKey Text -> Element Text -> a) -> a -> Text -> a Source #

MonoFoldableWithKey (Identity a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Identity a -> [(MonoKey (Identity a), Element (Identity a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Identity a) -> Element (Identity a) -> m) -> Identity a -> m Source #

ofoldrWithKey :: (MonoKey (Identity a) -> Element (Identity a) -> a0 -> a0) -> a0 -> Identity a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Identity a) -> Element (Identity a) -> a0) -> a0 -> Identity a -> a0 Source #

MonoFoldableWithKey (IntMap a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: IntMap a -> [(MonoKey (IntMap a), Element (IntMap a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (IntMap a) -> Element (IntMap a) -> m) -> IntMap a -> m Source #

ofoldrWithKey :: (MonoKey (IntMap a) -> Element (IntMap a) -> a0 -> a0) -> a0 -> IntMap a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (IntMap a) -> Element (IntMap a) -> a0) -> a0 -> IntMap a -> a0 Source #

MonoFoldableWithKey (Seq a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Seq a -> [(MonoKey (Seq a), Element (Seq a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Seq a) -> Element (Seq a) -> m) -> Seq a -> m Source #

ofoldrWithKey :: (MonoKey (Seq a) -> Element (Seq a) -> a0 -> a0) -> a0 -> Seq a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Seq a) -> Element (Seq a) -> a0) -> a0 -> Seq a -> a0 Source #

MonoFoldableWithKey (ViewL a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: ViewL a -> [(MonoKey (ViewL a), Element (ViewL a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (ViewL a) -> Element (ViewL a) -> m) -> ViewL a -> m Source #

ofoldrWithKey :: (MonoKey (ViewL a) -> Element (ViewL a) -> a0 -> a0) -> a0 -> ViewL a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (ViewL a) -> Element (ViewL a) -> a0) -> a0 -> ViewL a -> a0 Source #

MonoFoldableWithKey (ViewR a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: ViewR a -> [(MonoKey (ViewR a), Element (ViewR a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (ViewR a) -> Element (ViewR a) -> m) -> ViewR a -> m Source #

ofoldrWithKey :: (MonoKey (ViewR a) -> Element (ViewR a) -> a0 -> a0) -> a0 -> ViewR a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (ViewR a) -> Element (ViewR a) -> a0) -> a0 -> ViewR a -> a0 Source #

Ord e => MonoFoldableWithKey (Set e) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Set e -> [(MonoKey (Set e), Element (Set e))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Set e) -> Element (Set e) -> m) -> Set e -> m Source #

ofoldrWithKey :: (MonoKey (Set e) -> Element (Set e) -> a -> a) -> a -> Set e -> a Source #

ofoldlWithKey :: (a -> MonoKey (Set e) -> Element (Set e) -> a) -> a -> Set e -> a Source #

MonoFoldableWithKey (Tree a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Tree a -> [(MonoKey (Tree a), Element (Tree a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Tree a) -> Element (Tree a) -> m) -> Tree a -> m Source #

ofoldrWithKey :: (MonoKey (Tree a) -> Element (Tree a) -> a0 -> a0) -> a0 -> Tree a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Tree a) -> Element (Tree a) -> a0) -> a0 -> Tree a -> a0 Source #

MonoFoldableWithKey (HashSet v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: HashSet v -> [(MonoKey (HashSet v), Element (HashSet v))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (HashSet v) -> Element (HashSet v) -> m) -> HashSet v -> m Source #

ofoldrWithKey :: (MonoKey (HashSet v) -> Element (HashSet v) -> a -> a) -> a -> HashSet v -> a Source #

ofoldlWithKey :: (a -> MonoKey (HashSet v) -> Element (HashSet v) -> a) -> a -> HashSet v -> a Source #

MonoFoldableWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Vector a -> [(MonoKey (Vector a), Element (Vector a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Vector a) -> Element (Vector a) -> m) -> Vector a -> m Source #

ofoldrWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> a0 -> a0) -> a0 -> Vector a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Vector a) -> Element (Vector a) -> a0) -> a0 -> Vector a -> a0 Source #

Storable a => MonoFoldableWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Vector a -> [(MonoKey (Vector a), Element (Vector a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Vector a) -> Element (Vector a) -> m) -> Vector a -> m Source #

ofoldrWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> a0 -> a0) -> a0 -> Vector a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Vector a) -> Element (Vector a) -> a0) -> a0 -> Vector a -> a0 Source #

Unbox a => MonoFoldableWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Vector a -> [(MonoKey (Vector a), Element (Vector a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Vector a) -> Element (Vector a) -> m) -> Vector a -> m Source #

ofoldrWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> a0 -> a0) -> a0 -> Vector a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Vector a) -> Element (Vector a) -> a0) -> a0 -> Vector a -> a0 Source #

MonoFoldableWithKey (NonEmpty a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: NonEmpty a -> [(MonoKey (NonEmpty a), Element (NonEmpty a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (NonEmpty a) -> Element (NonEmpty a) -> m) -> NonEmpty a -> m Source #

ofoldrWithKey :: (MonoKey (NonEmpty a) -> Element (NonEmpty a) -> a0 -> a0) -> a0 -> NonEmpty a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (NonEmpty a) -> Element (NonEmpty a) -> a0) -> a0 -> NonEmpty a -> a0 Source #

MonoFoldableWithKey (Maybe a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Maybe a -> [(MonoKey (Maybe a), Element (Maybe a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Maybe a) -> Element (Maybe a) -> m) -> Maybe a -> m Source #

ofoldrWithKey :: (MonoKey (Maybe a) -> Element (Maybe a) -> a0 -> a0) -> a0 -> Maybe a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Maybe a) -> Element (Maybe a) -> a0) -> a0 -> Maybe a -> a0 Source #

MonoFoldableWithKey [a] Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: [a] -> [(MonoKey [a], Element [a])] Source #

ofoldMapWithKey :: Monoid m => (MonoKey [a] -> Element [a] -> m) -> [a] -> m Source #

ofoldrWithKey :: (MonoKey [a] -> Element [a] -> a0 -> a0) -> a0 -> [a] -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey [a] -> Element [a] -> a0) -> a0 -> [a] -> a0 Source #

MonoFoldableWithKey (Either a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Either a b -> [(MonoKey (Either a b), Element (Either a b))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Either a b) -> Element (Either a b) -> m) -> Either a b -> m Source #

ofoldrWithKey :: (MonoKey (Either a b) -> Element (Either a b) -> a0 -> a0) -> a0 -> Either a b -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Either a b) -> Element (Either a b) -> a0) -> a0 -> Either a b -> a0 Source #

MonoFoldableWithKey (Map k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Map k v -> [(MonoKey (Map k v), Element (Map k v))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Map k v) -> Element (Map k v) -> m) -> Map k v -> m Source #

ofoldrWithKey :: (MonoKey (Map k v) -> Element (Map k v) -> a -> a) -> a -> Map k v -> a Source #

ofoldlWithKey :: (a -> MonoKey (Map k v) -> Element (Map k v) -> a) -> a -> Map k v -> a Source #

Foldable f => MonoFoldableWithKey (ListT f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: ListT f a -> [(MonoKey (ListT f a), Element (ListT f a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (ListT f a) -> Element (ListT f a) -> m) -> ListT f a -> m Source #

ofoldrWithKey :: (MonoKey (ListT f a) -> Element (ListT f a) -> a0 -> a0) -> a0 -> ListT f a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (ListT f a) -> Element (ListT f a) -> a0) -> a0 -> ListT f a -> a0 Source #

Foldable f => MonoFoldableWithKey (MaybeT f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: MaybeT f a -> [(MonoKey (MaybeT f a), Element (MaybeT f a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (MaybeT f a) -> Element (MaybeT f a) -> m) -> MaybeT f a -> m Source #

ofoldrWithKey :: (MonoKey (MaybeT f a) -> Element (MaybeT f a) -> a0 -> a0) -> a0 -> MaybeT f a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (MaybeT f a) -> Element (MaybeT f a) -> a0) -> a0 -> MaybeT f a -> a0 Source #

MonoFoldableWithKey (HashMap k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: HashMap k v -> [(MonoKey (HashMap k v), Element (HashMap k v))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (HashMap k v) -> Element (HashMap k v) -> m) -> HashMap k v -> m Source #

ofoldrWithKey :: (MonoKey (HashMap k v) -> Element (HashMap k v) -> a -> a) -> a -> HashMap k v -> a Source #

ofoldlWithKey :: (a -> MonoKey (HashMap k v) -> Element (HashMap k v) -> a) -> a -> HashMap k v -> a Source #

MonoFoldableWithKey (a, b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: (a, b) -> [(MonoKey (a, b), Element (a, b))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (a, b) -> Element (a, b) -> m) -> (a, b) -> m Source #

ofoldrWithKey :: (MonoKey (a, b) -> Element (a, b) -> a0 -> a0) -> a0 -> (a, b) -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (a, b) -> Element (a, b) -> a0) -> a0 -> (a, b) -> a0 Source #

MonoFoldableWithKey (Const m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Const m a -> [(MonoKey (Const m a), Element (Const m a))] Source #

ofoldMapWithKey :: Monoid m0 => (MonoKey (Const m a) -> Element (Const m a) -> m0) -> Const m a -> m0 Source #

ofoldrWithKey :: (MonoKey (Const m a) -> Element (Const m a) -> a0 -> a0) -> a0 -> Const m a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Const m a) -> Element (Const m a) -> a0) -> a0 -> Const m a -> a0 Source #

Foldable f => MonoFoldableWithKey (IdentityT f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: IdentityT f a -> [(MonoKey (IdentityT f a), Element (IdentityT f a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (IdentityT f a) -> Element (IdentityT f a) -> m) -> IdentityT f a -> m Source #

ofoldrWithKey :: (MonoKey (IdentityT f a) -> Element (IdentityT f a) -> a0 -> a0) -> a0 -> IdentityT f a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (IdentityT f a) -> Element (IdentityT f a) -> a0) -> a0 -> IdentityT f a -> a0 Source #

Foldable f => MonoFoldableWithKey (WriterT w f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: WriterT w f a -> [(MonoKey (WriterT w f a), Element (WriterT w f a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (WriterT w f a) -> Element (WriterT w f a) -> m) -> WriterT w f a -> m Source #

ofoldrWithKey :: (MonoKey (WriterT w f a) -> Element (WriterT w f a) -> a0 -> a0) -> a0 -> WriterT w f a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (WriterT w f a) -> Element (WriterT w f a) -> a0) -> a0 -> WriterT w f a -> a0 Source #

Foldable f => MonoFoldableWithKey (WriterT w f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: WriterT w f a -> [(MonoKey (WriterT w f a), Element (WriterT w f a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (WriterT w f a) -> Element (WriterT w f a) -> m) -> WriterT w f a -> m Source #

ofoldrWithKey :: (MonoKey (WriterT w f a) -> Element (WriterT w f a) -> a0 -> a0) -> a0 -> WriterT w f a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (WriterT w f a) -> Element (WriterT w f a) -> a0) -> a0 -> WriterT w f a -> a0 Source #

(FoldableWithKey f, FoldableWithKey g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoFoldableWithKey (Product f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Product f g a -> [(MonoKey (Product f g a), Element (Product f g a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Product f g a) -> Element (Product f g a) -> m) -> Product f g a -> m Source #

ofoldrWithKey :: (MonoKey (Product f g a) -> Element (Product f g a) -> a0 -> a0) -> a0 -> Product f g a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Product f g a) -> Element (Product f g a) -> a0) -> a0 -> Product f g a -> a0 Source #

(FoldableWithKey f, FoldableWithKey g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoFoldableWithKey (Compose f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otoKeyedList :: Compose f g a -> [(MonoKey (Compose f g a), Element (Compose f g a))] Source #

ofoldMapWithKey :: Monoid m => (MonoKey (Compose f g a) -> Element (Compose f g a) -> m) -> Compose f g a -> m Source #

ofoldrWithKey :: (MonoKey (Compose f g a) -> Element (Compose f g a) -> a0 -> a0) -> a0 -> Compose f g a -> a0 Source #

ofoldlWithKey :: (a0 -> MonoKey (Compose f g a) -> Element (Compose f g a) -> a0) -> a0 -> Compose f g a -> a0 Source #

class (MonoKeyed mono, MonoFoldableWithKey mono, MonoTraversable mono) => MonoTraversableWithKey mono where Source #

Monomorphic containers that can be traversed from left to right over thier pairs of elements and corresponding keys.

Minimal complete definition

otraverseWithKey

Methods

otraverseWithKey :: Applicative f => (MonoKey mono -> Element mono -> f (Element mono)) -> mono -> f mono Source #

Map each key-element pair of a monomorphic container to an action, evaluate these actions from left to right, and collect the results. {-# INLINE otraverseWithKey #-}

default otraverseWithKey :: (Applicative f, TraversableWithKey t, Element (t a) ~ a, MonoKey (t a) ~ Key t, t a ~ mono) => (MonoKey mono -> Element mono -> f (Element mono)) -> mono -> f mono Source #

omapWithKeyM :: Monad m => (MonoKey mono -> Element mono -> m (Element mono)) -> mono -> m mono Source #

Like otraverse but with a Monad constraint.

Instances

Instances details
MonoTraversableWithKey ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoTraversableWithKey ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoTraversableWithKey Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoTraversableWithKey Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoTraversableWithKey (Identity a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Identity a) -> Element (Identity a) -> f (Element (Identity a))) -> Identity a -> f (Identity a) Source #

omapWithKeyM :: Monad m => (MonoKey (Identity a) -> Element (Identity a) -> m (Element (Identity a))) -> Identity a -> m (Identity a) Source #

MonoTraversableWithKey (IntMap a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (IntMap a) -> Element (IntMap a) -> f (Element (IntMap a))) -> IntMap a -> f (IntMap a) Source #

omapWithKeyM :: Monad m => (MonoKey (IntMap a) -> Element (IntMap a) -> m (Element (IntMap a))) -> IntMap a -> m (IntMap a) Source #

MonoTraversableWithKey (Seq a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Seq a) -> Element (Seq a) -> f (Element (Seq a))) -> Seq a -> f (Seq a) Source #

omapWithKeyM :: Monad m => (MonoKey (Seq a) -> Element (Seq a) -> m (Element (Seq a))) -> Seq a -> m (Seq a) Source #

MonoTraversableWithKey (ViewL a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (ViewL a) -> Element (ViewL a) -> f (Element (ViewL a))) -> ViewL a -> f (ViewL a) Source #

omapWithKeyM :: Monad m => (MonoKey (ViewL a) -> Element (ViewL a) -> m (Element (ViewL a))) -> ViewL a -> m (ViewL a) Source #

MonoTraversableWithKey (ViewR a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (ViewR a) -> Element (ViewR a) -> f (Element (ViewR a))) -> ViewR a -> f (ViewR a) Source #

omapWithKeyM :: Monad m => (MonoKey (ViewR a) -> Element (ViewR a) -> m (Element (ViewR a))) -> ViewR a -> m (ViewR a) Source #

MonoTraversableWithKey (Tree a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Tree a) -> Element (Tree a) -> f (Element (Tree a))) -> Tree a -> f (Tree a) Source #

omapWithKeyM :: Monad m => (MonoKey (Tree a) -> Element (Tree a) -> m (Element (Tree a))) -> Tree a -> m (Tree a) Source #

MonoTraversableWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Vector a) -> Element (Vector a) -> f (Element (Vector a))) -> Vector a -> f (Vector a) Source #

omapWithKeyM :: Monad m => (MonoKey (Vector a) -> Element (Vector a) -> m (Element (Vector a))) -> Vector a -> m (Vector a) Source #

Storable a => MonoTraversableWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Vector a) -> Element (Vector a) -> f (Element (Vector a))) -> Vector a -> f (Vector a) Source #

omapWithKeyM :: Monad m => (MonoKey (Vector a) -> Element (Vector a) -> m (Element (Vector a))) -> Vector a -> m (Vector a) Source #

Unbox a => MonoTraversableWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Vector a) -> Element (Vector a) -> f (Element (Vector a))) -> Vector a -> f (Vector a) Source #

omapWithKeyM :: Monad m => (MonoKey (Vector a) -> Element (Vector a) -> m (Element (Vector a))) -> Vector a -> m (Vector a) Source #

MonoTraversableWithKey (NonEmpty a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (NonEmpty a) -> Element (NonEmpty a) -> f (Element (NonEmpty a))) -> NonEmpty a -> f (NonEmpty a) Source #

omapWithKeyM :: Monad m => (MonoKey (NonEmpty a) -> Element (NonEmpty a) -> m (Element (NonEmpty a))) -> NonEmpty a -> m (NonEmpty a) Source #

MonoTraversableWithKey (Maybe a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Maybe a) -> Element (Maybe a) -> f (Element (Maybe a))) -> Maybe a -> f (Maybe a) Source #

omapWithKeyM :: Monad m => (MonoKey (Maybe a) -> Element (Maybe a) -> m (Element (Maybe a))) -> Maybe a -> m (Maybe a) Source #

MonoTraversableWithKey [a] Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey [a] -> Element [a] -> f (Element [a])) -> [a] -> f [a] Source #

omapWithKeyM :: Monad m => (MonoKey [a] -> Element [a] -> m (Element [a])) -> [a] -> m [a] Source #

MonoTraversableWithKey (Either a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Either a b) -> Element (Either a b) -> f (Element (Either a b))) -> Either a b -> f (Either a b) Source #

omapWithKeyM :: Monad m => (MonoKey (Either a b) -> Element (Either a b) -> m (Element (Either a b))) -> Either a b -> m (Either a b) Source #

MonoTraversableWithKey (Map k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Map k v) -> Element (Map k v) -> f (Element (Map k v))) -> Map k v -> f (Map k v) Source #

omapWithKeyM :: Monad m => (MonoKey (Map k v) -> Element (Map k v) -> m (Element (Map k v))) -> Map k v -> m (Map k v) Source #

Traversable f => MonoTraversableWithKey (ListT f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f0 => (MonoKey (ListT f a) -> Element (ListT f a) -> f0 (Element (ListT f a))) -> ListT f a -> f0 (ListT f a) Source #

omapWithKeyM :: Monad m => (MonoKey (ListT f a) -> Element (ListT f a) -> m (Element (ListT f a))) -> ListT f a -> m (ListT f a) Source #

Traversable f => MonoTraversableWithKey (MaybeT f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f0 => (MonoKey (MaybeT f a) -> Element (MaybeT f a) -> f0 (Element (MaybeT f a))) -> MaybeT f a -> f0 (MaybeT f a) Source #

omapWithKeyM :: Monad m => (MonoKey (MaybeT f a) -> Element (MaybeT f a) -> m (Element (MaybeT f a))) -> MaybeT f a -> m (MaybeT f a) Source #

MonoTraversableWithKey (HashMap k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (HashMap k v) -> Element (HashMap k v) -> f (Element (HashMap k v))) -> HashMap k v -> f (HashMap k v) Source #

omapWithKeyM :: Monad m => (MonoKey (HashMap k v) -> Element (HashMap k v) -> m (Element (HashMap k v))) -> HashMap k v -> m (HashMap k v) Source #

MonoTraversableWithKey (a, b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (a, b) -> Element (a, b) -> f (Element (a, b))) -> (a, b) -> f (a, b) Source #

omapWithKeyM :: Monad m => (MonoKey (a, b) -> Element (a, b) -> m (Element (a, b))) -> (a, b) -> m (a, b) Source #

MonoTraversableWithKey (Const m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f => (MonoKey (Const m a) -> Element (Const m a) -> f (Element (Const m a))) -> Const m a -> f (Const m a) Source #

omapWithKeyM :: Monad m0 => (MonoKey (Const m a) -> Element (Const m a) -> m0 (Element (Const m a))) -> Const m a -> m0 (Const m a) Source #

Traversable f => MonoTraversableWithKey (IdentityT f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f0 => (MonoKey (IdentityT f a) -> Element (IdentityT f a) -> f0 (Element (IdentityT f a))) -> IdentityT f a -> f0 (IdentityT f a) Source #

omapWithKeyM :: Monad m => (MonoKey (IdentityT f a) -> Element (IdentityT f a) -> m (Element (IdentityT f a))) -> IdentityT f a -> m (IdentityT f a) Source #

Traversable f => MonoTraversableWithKey (WriterT w f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f0 => (MonoKey (WriterT w f a) -> Element (WriterT w f a) -> f0 (Element (WriterT w f a))) -> WriterT w f a -> f0 (WriterT w f a) Source #

omapWithKeyM :: Monad m => (MonoKey (WriterT w f a) -> Element (WriterT w f a) -> m (Element (WriterT w f a))) -> WriterT w f a -> m (WriterT w f a) Source #

Traversable f => MonoTraversableWithKey (WriterT w f a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f0 => (MonoKey (WriterT w f a) -> Element (WriterT w f a) -> f0 (Element (WriterT w f a))) -> WriterT w f a -> f0 (WriterT w f a) Source #

omapWithKeyM :: Monad m => (MonoKey (WriterT w f a) -> Element (WriterT w f a) -> m (Element (WriterT w f a))) -> WriterT w f a -> m (WriterT w f a) Source #

(MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g, TraversableWithKey f, TraversableWithKey g) => MonoTraversableWithKey (Product f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f0 => (MonoKey (Product f g a) -> Element (Product f g a) -> f0 (Element (Product f g a))) -> Product f g a -> f0 (Product f g a) Source #

omapWithKeyM :: Monad m => (MonoKey (Product f g a) -> Element (Product f g a) -> m (Element (Product f g a))) -> Product f g a -> m (Product f g a) Source #

(MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g, TraversableWithKey f, TraversableWithKey g) => MonoTraversableWithKey (Compose f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

otraverseWithKey :: Applicative f0 => (MonoKey (Compose f g a) -> Element (Compose f g a) -> f0 (Element (Compose f g a))) -> Compose f g a -> f0 (Compose f g a) Source #

omapWithKeyM :: Monad m => (MonoKey (Compose f g a) -> Element (Compose f g a) -> m (Element (Compose f g a))) -> Compose f g a -> m (Compose f g a) Source #

Adjustable Monomorphic Structures

class MonoFunctor mono => MonoAdjustable mono where Source #

Monomorphic container that can adjust elements "in place."

Minimal complete definition

oadjust

Methods

oadjust :: (Element mono -> Element mono) -> MonoKey mono -> mono -> mono Source #

default oadjust :: (Adjustable f, Element (f a) ~ a, MonoKey (f a) ~ Key f, f a ~ mono) => (Element mono -> Element mono) -> MonoKey mono -> mono -> mono Source #

oreplace :: MonoKey mono -> Element mono -> mono -> mono Source #

Instances

Instances details
MonoAdjustable ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoAdjustable ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoAdjustable Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoAdjustable Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoAdjustable (ZipList a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoAdjustable (Identity a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoAdjustable (IntMap a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (IntMap a) -> Element (IntMap a)) -> MonoKey (IntMap a) -> IntMap a -> IntMap a Source #

oreplace :: MonoKey (IntMap a) -> Element (IntMap a) -> IntMap a -> IntMap a Source #

MonoAdjustable (Seq a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Seq a) -> Element (Seq a)) -> MonoKey (Seq a) -> Seq a -> Seq a Source #

oreplace :: MonoKey (Seq a) -> Element (Seq a) -> Seq a -> Seq a Source #

MonoAdjustable (ViewL a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (ViewL a) -> Element (ViewL a)) -> MonoKey (ViewL a) -> ViewL a -> ViewL a Source #

oreplace :: MonoKey (ViewL a) -> Element (ViewL a) -> ViewL a -> ViewL a Source #

MonoAdjustable (ViewR a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (ViewR a) -> Element (ViewR a)) -> MonoKey (ViewR a) -> ViewR a -> ViewR a Source #

oreplace :: MonoKey (ViewR a) -> Element (ViewR a) -> ViewR a -> ViewR a Source #

MonoAdjustable (Tree a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Tree a) -> Element (Tree a)) -> MonoKey (Tree a) -> Tree a -> Tree a Source #

oreplace :: MonoKey (Tree a) -> Element (Tree a) -> Tree a -> Tree a Source #

MonoAdjustable (IO a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (IO a) -> Element (IO a)) -> MonoKey (IO a) -> IO a -> IO a Source #

oreplace :: MonoKey (IO a) -> Element (IO a) -> IO a -> IO a Source #

MonoAdjustable (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Vector a) -> Element (Vector a)) -> MonoKey (Vector a) -> Vector a -> Vector a Source #

oreplace :: MonoKey (Vector a) -> Element (Vector a) -> Vector a -> Vector a Source #

Storable a => MonoAdjustable (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Vector a) -> Element (Vector a)) -> MonoKey (Vector a) -> Vector a -> Vector a Source #

oreplace :: MonoKey (Vector a) -> Element (Vector a) -> Vector a -> Vector a Source #

Unbox a => MonoAdjustable (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Vector a) -> Element (Vector a)) -> MonoKey (Vector a) -> Vector a -> Vector a Source #

oreplace :: MonoKey (Vector a) -> Element (Vector a) -> Vector a -> Vector a Source #

MonoAdjustable (NonEmpty a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoAdjustable (Maybe a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Maybe a) -> Element (Maybe a)) -> MonoKey (Maybe a) -> Maybe a -> Maybe a Source #

oreplace :: MonoKey (Maybe a) -> Element (Maybe a) -> Maybe a -> Maybe a Source #

MonoAdjustable [a] Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element [a] -> Element [a]) -> MonoKey [a] -> [a] -> [a] Source #

oreplace :: MonoKey [a] -> Element [a] -> [a] -> [a] Source #

Monad m => MonoAdjustable (WrappedMonad m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoAdjustable (Either a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Either a b) -> Element (Either a b)) -> MonoKey (Either a b) -> Either a b -> Either a b Source #

oreplace :: MonoKey (Either a b) -> Element (Either a b) -> Either a b -> Either a b Source #

MonoAdjustable (Arg a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Arg a b) -> Element (Arg a b)) -> MonoKey (Arg a b) -> Arg a b -> Arg a b Source #

oreplace :: MonoKey (Arg a b) -> Element (Arg a b) -> Arg a b -> Arg a b Source #

Ord k => MonoAdjustable (Map k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Map k v) -> Element (Map k v)) -> MonoKey (Map k v) -> Map k v -> Map k v Source #

oreplace :: MonoKey (Map k v) -> Element (Map k v) -> Map k v -> Map k v Source #

Functor m => MonoAdjustable (ListT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (ListT m a) -> Element (ListT m a)) -> MonoKey (ListT m a) -> ListT m a -> ListT m a Source #

oreplace :: MonoKey (ListT m a) -> Element (ListT m a) -> ListT m a -> ListT m a Source #

Functor m => MonoAdjustable (MaybeT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (MaybeT m a) -> Element (MaybeT m a)) -> MonoKey (MaybeT m a) -> MaybeT m a -> MaybeT m a Source #

oreplace :: MonoKey (MaybeT m a) -> Element (MaybeT m a) -> MaybeT m a -> MaybeT m a Source #

(Eq k, Hashable k) => MonoAdjustable (HashMap k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (HashMap k v) -> Element (HashMap k v)) -> MonoKey (HashMap k v) -> HashMap k v -> HashMap k v Source #

oreplace :: MonoKey (HashMap k v) -> Element (HashMap k v) -> HashMap k v -> HashMap k v Source #

MonoAdjustable (r -> a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (r -> a) -> Element (r -> a)) -> MonoKey (r -> a) -> (r -> a) -> r -> a Source #

oreplace :: MonoKey (r -> a) -> Element (r -> a) -> (r -> a) -> r -> a Source #

MonoAdjustable (a, b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (a, b) -> Element (a, b)) -> MonoKey (a, b) -> (a, b) -> (a, b) Source #

oreplace :: MonoKey (a, b) -> Element (a, b) -> (a, b) -> (a, b) Source #

Arrow a => MonoAdjustable (WrappedArrow a b c) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (WrappedArrow a b c) -> Element (WrappedArrow a b c)) -> MonoKey (WrappedArrow a b c) -> WrappedArrow a b c -> WrappedArrow a b c Source #

oreplace :: MonoKey (WrappedArrow a b c) -> Element (WrappedArrow a b c) -> WrappedArrow a b c -> WrappedArrow a b c Source #

MonoAdjustable (Const m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Const m a) -> Element (Const m a)) -> MonoKey (Const m a) -> Const m a -> Const m a Source #

oreplace :: MonoKey (Const m a) -> Element (Const m a) -> Const m a -> Const m a Source #

Functor m => MonoAdjustable (IdentityT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (IdentityT m a) -> Element (IdentityT m a)) -> MonoKey (IdentityT m a) -> IdentityT m a -> IdentityT m a Source #

oreplace :: MonoKey (IdentityT m a) -> Element (IdentityT m a) -> IdentityT m a -> IdentityT m a Source #

Functor m => MonoAdjustable (ReaderT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (ReaderT r m a) -> Element (ReaderT r m a)) -> MonoKey (ReaderT r m a) -> ReaderT r m a -> ReaderT r m a Source #

oreplace :: MonoKey (ReaderT r m a) -> Element (ReaderT r m a) -> ReaderT r m a -> ReaderT r m a Source #

Functor m => MonoAdjustable (StateT s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (StateT s m a) -> Element (StateT s m a)) -> MonoKey (StateT s m a) -> StateT s m a -> StateT s m a Source #

oreplace :: MonoKey (StateT s m a) -> Element (StateT s m a) -> StateT s m a -> StateT s m a Source #

Functor m => MonoAdjustable (StateT s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (StateT s m a) -> Element (StateT s m a)) -> MonoKey (StateT s m a) -> StateT s m a -> StateT s m a Source #

oreplace :: MonoKey (StateT s m a) -> Element (StateT s m a) -> StateT s m a -> StateT s m a Source #

Functor m => MonoAdjustable (WriterT w m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (WriterT w m a) -> Element (WriterT w m a)) -> MonoKey (WriterT w m a) -> WriterT w m a -> WriterT w m a Source #

oreplace :: MonoKey (WriterT w m a) -> Element (WriterT w m a) -> WriterT w m a -> WriterT w m a Source #

Functor m => MonoAdjustable (WriterT w m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (WriterT w m a) -> Element (WriterT w m a)) -> MonoKey (WriterT w m a) -> WriterT w m a -> WriterT w m a Source #

oreplace :: MonoKey (WriterT w m a) -> Element (WriterT w m a) -> WriterT w m a -> WriterT w m a Source #

(Adjustable f, Adjustable g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoAdjustable (Product f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (Product f g a) -> Element (Product f g a)) -> MonoKey (Product f g a) -> Product f g a -> Product f g a Source #

oreplace :: MonoKey (Product f g a) -> Element (Product f g a) -> Product f g a -> Product f g a Source #

Functor m => MonoAdjustable (ContT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (ContT r m a) -> Element (ContT r m a)) -> MonoKey (ContT r m a) -> ContT r m a -> ContT r m a Source #

oreplace :: MonoKey (ContT r m a) -> Element (ContT r m a) -> ContT r m a -> ContT r m a Source #

Functor m => MonoAdjustable (RWST r w s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (RWST r w s m a) -> Element (RWST r w s m a)) -> MonoKey (RWST r w s m a) -> RWST r w s m a -> RWST r w s m a Source #

oreplace :: MonoKey (RWST r w s m a) -> Element (RWST r w s m a) -> RWST r w s m a -> RWST r w s m a Source #

Functor m => MonoAdjustable (RWST r w s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oadjust :: (Element (RWST r w s m a) -> Element (RWST r w s m a)) -> MonoKey (RWST r w s m a) -> RWST r w s m a -> RWST r w s m a Source #

oreplace :: MonoKey (RWST r w s m a) -> Element (RWST r w s m a) -> RWST r w s m a -> RWST r w s m a Source #

Zippable Monomorphic Structures

class MonoFunctor mono => MonoZip mono where Source #

Monomorphic container that can be zipped together, merging thier elements.

Laws:

ozipWith const u u === ozipWith (flip const) u u === u
ozipWith (flip f) x y === ozipWith f y x
ozipWith (a b -> f (g a) (h b)) x y === ozipWith f (omap g x) (omap h y)

Methods

ozipWith :: (Element mono -> Element mono -> Element mono) -> mono -> mono -> mono Source #

Instances

Instances details
MonoZip ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZip ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZip Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZip Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZip (ZipList a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (ZipList a) -> Element (ZipList a) -> Element (ZipList a)) -> ZipList a -> ZipList a -> ZipList a Source #

MonoZip (Identity a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Identity a) -> Element (Identity a) -> Element (Identity a)) -> Identity a -> Identity a -> Identity a Source #

MonoZip (IntMap a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (IntMap a) -> Element (IntMap a) -> Element (IntMap a)) -> IntMap a -> IntMap a -> IntMap a Source #

MonoZip (Seq a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Seq a) -> Element (Seq a) -> Element (Seq a)) -> Seq a -> Seq a -> Seq a Source #

MonoZip (ViewL a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (ViewL a) -> Element (ViewL a) -> Element (ViewL a)) -> ViewL a -> ViewL a -> ViewL a Source #

MonoZip (ViewR a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (ViewR a) -> Element (ViewR a) -> Element (ViewR a)) -> ViewR a -> ViewR a -> ViewR a Source #

MonoZip (Tree a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Tree a) -> Element (Tree a) -> Element (Tree a)) -> Tree a -> Tree a -> Tree a Source #

MonoZip (IO a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (IO a) -> Element (IO a) -> Element (IO a)) -> IO a -> IO a -> IO a Source #

MonoZip (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a -> Vector a Source #

Storable a => MonoZip (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a -> Vector a Source #

Unbox a => MonoZip (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a -> Vector a Source #

MonoZip (NonEmpty a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (NonEmpty a) -> Element (NonEmpty a) -> Element (NonEmpty a)) -> NonEmpty a -> NonEmpty a -> NonEmpty a Source #

MonoZip (Maybe a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Maybe a) -> Element (Maybe a) -> Element (Maybe a)) -> Maybe a -> Maybe a -> Maybe a Source #

MonoZip [a] Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element [a] -> Element [a] -> Element [a]) -> [a] -> [a] -> [a] Source #

Monad m => MonoZip (WrappedMonad m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZip (Either a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Either a b) -> Element (Either a b) -> Element (Either a b)) -> Either a b -> Either a b -> Either a b Source #

MonoZip (Arg a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Arg a b) -> Element (Arg a b) -> Element (Arg a b)) -> Arg a b -> Arg a b -> Arg a b Source #

Ord k => MonoZip (Map k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Map k v) -> Element (Map k v) -> Element (Map k v)) -> Map k v -> Map k v -> Map k v Source #

Applicative m => MonoZip (ListT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (ListT m a) -> Element (ListT m a) -> Element (ListT m a)) -> ListT m a -> ListT m a -> ListT m a Source #

Applicative m => MonoZip (MaybeT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (MaybeT m a) -> Element (MaybeT m a) -> Element (MaybeT m a)) -> MaybeT m a -> MaybeT m a -> MaybeT m a Source #

(Eq k, Hashable k) => MonoZip (HashMap k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (HashMap k v) -> Element (HashMap k v) -> Element (HashMap k v)) -> HashMap k v -> HashMap k v -> HashMap k v Source #

MonoZip (r -> a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (r -> a) -> Element (r -> a) -> Element (r -> a)) -> (r -> a) -> (r -> a) -> r -> a Source #

MonoZip (a, b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (a, b) -> Element (a, b) -> Element (a, b)) -> (a, b) -> (a, b) -> (a, b) Source #

Arrow a => MonoZip (WrappedArrow a b c) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (WrappedArrow a b c) -> Element (WrappedArrow a b c) -> Element (WrappedArrow a b c)) -> WrappedArrow a b c -> WrappedArrow a b c -> WrappedArrow a b c Source #

MonoZip (Const m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Const m a) -> Element (Const m a) -> Element (Const m a)) -> Const m a -> Const m a -> Const m a Source #

Applicative m => MonoZip (IdentityT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (IdentityT m a) -> Element (IdentityT m a) -> Element (IdentityT m a)) -> IdentityT m a -> IdentityT m a -> IdentityT m a Source #

Applicative m => MonoZip (ReaderT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (ReaderT r m a) -> Element (ReaderT r m a) -> Element (ReaderT r m a)) -> ReaderT r m a -> ReaderT r m a -> ReaderT r m a Source #

Applicative m => MonoZip (StateT s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (StateT s m a) -> Element (StateT s m a) -> Element (StateT s m a)) -> StateT s m a -> StateT s m a -> StateT s m a Source #

Applicative m => MonoZip (StateT s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (StateT s m a) -> Element (StateT s m a) -> Element (StateT s m a)) -> StateT s m a -> StateT s m a -> StateT s m a Source #

(Applicative m, Monoid w) => MonoZip (WriterT w m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (WriterT w m a) -> Element (WriterT w m a) -> Element (WriterT w m a)) -> WriterT w m a -> WriterT w m a -> WriterT w m a Source #

(Applicative m, Monoid w) => MonoZip (WriterT w m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (WriterT w m a) -> Element (WriterT w m a) -> Element (WriterT w m a)) -> WriterT w m a -> WriterT w m a -> WriterT w m a Source #

(Zip f, Zip g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoZip (Product f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Product f g a) -> Element (Product f g a) -> Element (Product f g a)) -> Product f g a -> Product f g a -> Product f g a Source #

Functor m => MonoZip (ContT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (ContT r m a) -> Element (ContT r m a) -> Element (ContT r m a)) -> ContT r m a -> ContT r m a -> ContT r m a Source #

(Zip f, Zip g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoZip (Compose f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (Compose f g a) -> Element (Compose f g a) -> Element (Compose f g a)) -> Compose f g a -> Compose f g a -> Compose f g a Source #

(Applicative m, Semigroup w) => MonoZip (RWST r w s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (RWST r w s m a) -> Element (RWST r w s m a) -> Element (RWST r w s m a)) -> RWST r w s m a -> RWST r w s m a -> RWST r w s m a Source #

(Applicative m, Semigroup w) => MonoZip (RWST r w s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWith :: (Element (RWST r w s m a) -> Element (RWST r w s m a) -> Element (RWST r w s m a)) -> RWST r w s m a -> RWST r w s m a -> RWST r w s m a Source #

class (MonoKeyed mono, MonoZip mono) => MonoZipWithKey mono where Source #

Monomorphic container that can be zipped together, merging thier pairs of elements and corresponding keys.

Methods

ozipWithKey :: (MonoKey mono -> Element mono -> Element mono -> Element mono) -> mono -> mono -> mono Source #

Instances

Instances details
MonoZipWithKey ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZipWithKey ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZipWithKey Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZipWithKey Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZipWithKey (ZipList a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (ZipList a) -> Element (ZipList a) -> Element (ZipList a) -> Element (ZipList a)) -> ZipList a -> ZipList a -> ZipList a Source #

MonoZipWithKey (Identity a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZipWithKey (IntMap a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (IntMap a) -> Element (IntMap a) -> Element (IntMap a) -> Element (IntMap a)) -> IntMap a -> IntMap a -> IntMap a Source #

MonoZipWithKey (Seq a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Seq a) -> Element (Seq a) -> Element (Seq a) -> Element (Seq a)) -> Seq a -> Seq a -> Seq a Source #

MonoZipWithKey (ViewL a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (ViewL a) -> Element (ViewL a) -> Element (ViewL a) -> Element (ViewL a)) -> ViewL a -> ViewL a -> ViewL a Source #

MonoZipWithKey (ViewR a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (ViewR a) -> Element (ViewR a) -> Element (ViewR a) -> Element (ViewR a)) -> ViewR a -> ViewR a -> ViewR a Source #

MonoZipWithKey (Tree a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Tree a) -> Element (Tree a) -> Element (Tree a) -> Element (Tree a)) -> Tree a -> Tree a -> Tree a Source #

MonoZipWithKey (IO a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (IO a) -> Element (IO a) -> Element (IO a) -> Element (IO a)) -> IO a -> IO a -> IO a Source #

MonoZipWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a -> Vector a Source #

Storable a => MonoZipWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a -> Vector a Source #

Unbox a => MonoZipWithKey (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Vector a) -> Element (Vector a) -> Element (Vector a) -> Element (Vector a)) -> Vector a -> Vector a -> Vector a Source #

MonoZipWithKey (NonEmpty a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZipWithKey (Maybe a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Maybe a) -> Element (Maybe a) -> Element (Maybe a) -> Element (Maybe a)) -> Maybe a -> Maybe a -> Maybe a Source #

MonoZipWithKey [a] Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey [a] -> Element [a] -> Element [a] -> Element [a]) -> [a] -> [a] -> [a] Source #

Monad m => MonoZipWithKey (WrappedMonad m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoZipWithKey (Either a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Either a b) -> Element (Either a b) -> Element (Either a b) -> Element (Either a b)) -> Either a b -> Either a b -> Either a b Source #

MonoZipWithKey (Arg a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Arg a b) -> Element (Arg a b) -> Element (Arg a b) -> Element (Arg a b)) -> Arg a b -> Arg a b -> Arg a b Source #

Ord k => MonoZipWithKey (Map k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Map k v) -> Element (Map k v) -> Element (Map k v) -> Element (Map k v)) -> Map k v -> Map k v -> Map k v Source #

Applicative m => MonoZipWithKey (ListT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (ListT m a) -> Element (ListT m a) -> Element (ListT m a) -> Element (ListT m a)) -> ListT m a -> ListT m a -> ListT m a Source #

Monad m => MonoZipWithKey (MaybeT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (MaybeT m a) -> Element (MaybeT m a) -> Element (MaybeT m a) -> Element (MaybeT m a)) -> MaybeT m a -> MaybeT m a -> MaybeT m a Source #

(Eq k, Hashable k) => MonoZipWithKey (HashMap k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (HashMap k v) -> Element (HashMap k v) -> Element (HashMap k v) -> Element (HashMap k v)) -> HashMap k v -> HashMap k v -> HashMap k v Source #

MonoZipWithKey (r -> a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (r -> a) -> Element (r -> a) -> Element (r -> a) -> Element (r -> a)) -> (r -> a) -> (r -> a) -> r -> a Source #

MonoZipWithKey (a, b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (a, b) -> Element (a, b) -> Element (a, b) -> Element (a, b)) -> (a, b) -> (a, b) -> (a, b) Source #

Arrow a => MonoZipWithKey (WrappedArrow a b c) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (WrappedArrow a b c) -> Element (WrappedArrow a b c) -> Element (WrappedArrow a b c) -> Element (WrappedArrow a b c)) -> WrappedArrow a b c -> WrappedArrow a b c -> WrappedArrow a b c Source #

MonoZipWithKey (Const m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Const m a) -> Element (Const m a) -> Element (Const m a) -> Element (Const m a)) -> Const m a -> Const m a -> Const m a Source #

Applicative m => MonoZipWithKey (IdentityT m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (IdentityT m a) -> Element (IdentityT m a) -> Element (IdentityT m a) -> Element (IdentityT m a)) -> IdentityT m a -> IdentityT m a -> IdentityT m a Source #

(Applicative m, ZipWithKey m) => MonoZipWithKey (ReaderT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (ReaderT r m a) -> Element (ReaderT r m a) -> Element (ReaderT r m a) -> Element (ReaderT r m a)) -> ReaderT r m a -> ReaderT r m a -> ReaderT r m a Source #

Applicative m => MonoZipWithKey (StateT s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (StateT s m a) -> Element (StateT s m a) -> Element (StateT s m a) -> Element (StateT s m a)) -> StateT s m a -> StateT s m a -> StateT s m a Source #

Applicative m => MonoZipWithKey (StateT s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (StateT s m a) -> Element (StateT s m a) -> Element (StateT s m a) -> Element (StateT s m a)) -> StateT s m a -> StateT s m a -> StateT s m a Source #

(Applicative m, Monoid w) => MonoZipWithKey (WriterT w m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (WriterT w m a) -> Element (WriterT w m a) -> Element (WriterT w m a) -> Element (WriterT w m a)) -> WriterT w m a -> WriterT w m a -> WriterT w m a Source #

(Applicative m, Monoid w) => MonoZipWithKey (WriterT w m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (WriterT w m a) -> Element (WriterT w m a) -> Element (WriterT w m a) -> Element (WriterT w m a)) -> WriterT w m a -> WriterT w m a -> WriterT w m a Source #

(ZipWithKey f, ZipWithKey g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoZipWithKey (Product f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Product f g a) -> Element (Product f g a) -> Element (Product f g a) -> Element (Product f g a)) -> Product f g a -> Product f g a -> Product f g a Source #

Functor m => MonoZipWithKey (ContT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (ContT r m a) -> Element (ContT r m a) -> Element (ContT r m a) -> Element (ContT r m a)) -> ContT r m a -> ContT r m a -> ContT r m a Source #

(ZipWithKey f, ZipWithKey g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoZipWithKey (Compose f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (Compose f g a) -> Element (Compose f g a) -> Element (Compose f g a) -> Element (Compose f g a)) -> Compose f g a -> Compose f g a -> Compose f g a Source #

(Applicative m, Semigroup w) => MonoZipWithKey (RWST r w s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (RWST r w s m a) -> Element (RWST r w s m a) -> Element (RWST r w s m a) -> Element (RWST r w s m a)) -> RWST r w s m a -> RWST r w s m a -> RWST r w s m a Source #

(Applicative m, Semigroup w) => MonoZipWithKey (RWST r w s m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

ozipWithKey :: (MonoKey (RWST r w s m a) -> Element (RWST r w s m a) -> Element (RWST r w s m a) -> Element (RWST r w s m a)) -> RWST r w s m a -> RWST r w s m a -> RWST r w s m a Source #

Monomorphic Indexing / Querries

class MonoLookup mono => MonoIndexable mono where Source #

Monomorphic container that can be indexed by a key for an element.

Minimal complete definition

oindex

Methods

oindex :: mono -> MonoKey mono -> Element mono Source #

default oindex :: (Indexable f, Element (f a) ~ a, MonoKey (f a) ~ Key f, f a ~ mono) => mono -> MonoKey mono -> Element mono Source #

Instances

Instances details
MonoIndexable ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoIndexable ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoIndexable IntSet Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoIndexable Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoIndexable Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoIndexable (ZipList a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: ZipList a -> MonoKey (ZipList a) -> Element (ZipList a) Source #

MonoIndexable (Identity a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoIndexable (IntMap a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: IntMap a -> MonoKey (IntMap a) -> Element (IntMap a) Source #

MonoIndexable (Seq a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Seq a -> MonoKey (Seq a) -> Element (Seq a) Source #

MonoIndexable (ViewL a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: ViewL a -> MonoKey (ViewL a) -> Element (ViewL a) Source #

MonoIndexable (ViewR a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: ViewR a -> MonoKey (ViewR a) -> Element (ViewR a) Source #

Ord a => MonoIndexable (Set a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Set a -> MonoKey (Set a) -> Element (Set a) Source #

MonoIndexable (Tree a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Tree a -> MonoKey (Tree a) -> Element (Tree a) Source #

MonoIndexable (HashSet v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: HashSet v -> MonoKey (HashSet v) -> Element (HashSet v) Source #

MonoIndexable (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Vector a -> MonoKey (Vector a) -> Element (Vector a) Source #

Storable a => MonoIndexable (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Vector a -> MonoKey (Vector a) -> Element (Vector a) Source #

Unbox a => MonoIndexable (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Vector a -> MonoKey (Vector a) -> Element (Vector a) Source #

MonoIndexable (NonEmpty a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoIndexable (Maybe a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Maybe a -> MonoKey (Maybe a) -> Element (Maybe a) Source #

MonoIndexable [a] Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: [a] -> MonoKey [a] -> Element [a] Source #

MonoIndexable (Either a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Either a b -> MonoKey (Either a b) -> Element (Either a b) Source #

MonoIndexable (Arg a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Arg a b -> MonoKey (Arg a b) -> Element (Arg a b) Source #

Ord k => MonoIndexable (Map k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Map k v -> MonoKey (Map k v) -> Element (Map k v) Source #

(Eq k, Hashable k) => MonoIndexable (HashMap k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: HashMap k v -> MonoKey (HashMap k v) -> Element (HashMap k v) Source #

MonoIndexable (a, b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: (a, b) -> MonoKey (a, b) -> Element (a, b) Source #

Indexable m => MonoIndexable (ReaderT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: ReaderT r m a -> MonoKey (ReaderT r m a) -> Element (ReaderT r m a) Source #

(Indexable f, Indexable g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoIndexable (Product f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Product f g a -> MonoKey (Product f g a) -> Element (Product f g a) Source #

(Indexable f, Indexable g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoIndexable (Compose f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

oindex :: Compose f g a -> MonoKey (Compose f g a) -> Element (Compose f g a) Source #

class MonoLookup mono where Source #

Monomorphic container that can be querried by a key for an element.

Minimal complete definition

olookup

Methods

olookup :: MonoKey mono -> mono -> Maybe (Element mono) Source #

default olookup :: (Lookup f, Element (f a) ~ a, MonoKey (f a) ~ Key f, f a ~ mono) => MonoKey mono -> mono -> Maybe (Element mono) Source #

Instances

Instances details
MonoLookup ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoLookup ByteString Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoLookup IntSet Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoLookup Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoLookup Text Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoLookup (ZipList a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (ZipList a) -> ZipList a -> Maybe (Element (ZipList a)) Source #

MonoLookup (Identity a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoLookup (IntMap a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (IntMap a) -> IntMap a -> Maybe (Element (IntMap a)) Source #

MonoLookup (Seq a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Seq a) -> Seq a -> Maybe (Element (Seq a)) Source #

MonoLookup (ViewL a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (ViewL a) -> ViewL a -> Maybe (Element (ViewL a)) Source #

MonoLookup (ViewR a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (ViewR a) -> ViewR a -> Maybe (Element (ViewR a)) Source #

Ord a => MonoLookup (Set a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Set a) -> Set a -> Maybe (Element (Set a)) Source #

MonoLookup (Tree a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Tree a) -> Tree a -> Maybe (Element (Tree a)) Source #

MonoLookup (HashSet v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (HashSet v) -> HashSet v -> Maybe (Element (HashSet v)) Source #

MonoLookup (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Vector a) -> Vector a -> Maybe (Element (Vector a)) Source #

Storable a => MonoLookup (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Vector a) -> Vector a -> Maybe (Element (Vector a)) Source #

Unbox a => MonoLookup (Vector a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Vector a) -> Vector a -> Maybe (Element (Vector a)) Source #

MonoLookup (NonEmpty a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

MonoLookup (Maybe a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Maybe a) -> Maybe a -> Maybe (Element (Maybe a)) Source #

MonoLookup [a] Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey [a] -> [a] -> Maybe (Element [a]) Source #

MonoLookup (Either a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Either a b) -> Either a b -> Maybe (Element (Either a b)) Source #

MonoLookup (Arg a b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Arg a b) -> Arg a b -> Maybe (Element (Arg a b)) Source #

Ord k => MonoLookup (Map k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Map k v) -> Map k v -> Maybe (Element (Map k v)) Source #

(Eq k, Hashable k) => MonoLookup (HashMap k v) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (HashMap k v) -> HashMap k v -> Maybe (Element (HashMap k v)) Source #

MonoLookup (a, b) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (a, b) -> (a, b) -> Maybe (Element (a, b)) Source #

Lookup m => MonoLookup (ReaderT r m a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (ReaderT r m a) -> ReaderT r m a -> Maybe (Element (ReaderT r m a)) Source #

(Lookup f, Lookup g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoLookup (Product f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Product f g a) -> Product f g a -> Maybe (Element (Product f g a)) Source #

(Lookup f, Lookup g, MonoKey (f a) ~ Key f, MonoKey (g a) ~ Key g) => MonoLookup (Compose f g a) Source #

Since: 0.1.0

Instance details

Defined in Data.MonoTraversable.Keys

Methods

olookup :: MonoKey (Compose f g a) -> Compose f g a -> Maybe (Element (Compose f g a)) Source #

Monomorphic unwrapping with key

ofoldlWithKeyUnwrap :: MonoFoldableWithKey mono => (x -> Element mono -> x) -> x -> (x -> b) -> mono -> b Source #

A strict left fold, together with an unwrap function.

This is convenient when the accumulator value is not the same as the final expected type. It is provided mainly for integration with the foldl package, to be used in conjunction with purely.

Since: 0.1.0

ofoldWithKeyMUnwrap :: (Monad m, MonoFoldableWithKey mono) => (x -> Element mono -> m x) -> m x -> (x -> m b) -> mono -> m b Source #

A monadic strict left fold, together with an unwrap function.

Similar to foldlUnwrap, but allows monadic actions. To be used with impurely from foldl.

Since: 0.1.0