Copyright | Copyright (c) 2006 2008 Robert Dockins |
---|---|
License | MIT; see COPYRIGHT file for terms and conditions |
Maintainer | robdockins AT fastmail DOT fm |
Stability | stable |
Portability | GHC, Hugs (MPTC and FD) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Data.Edison.Assoc.StandardMap
Description
The standard library Data.Map repackaged as an Edison associative collection.
Synopsis
- type FM = Map
- empty :: FM k a
- singleton :: Ord k => k -> a -> FM k a
- fromSeq :: (Ord k, Sequence seq) => seq (k, a) -> FM k a
- insert :: Ord k => k -> a -> FM k a -> FM k a
- insertSeq :: (Ord k, Sequence seq) => seq (k, a) -> FM k a -> FM k a
- union :: Ord k => FM k a -> FM k a -> FM k a
- unionSeq :: (Ord k, Sequence seq) => seq (FM k a) -> FM k a
- delete :: Ord k => k -> FM k a -> FM k a
- deleteAll :: Ord k => k -> FM k a -> FM k a
- deleteSeq :: (Ord k, Sequence seq) => seq k -> FM k a -> FM k a
- null :: FM k a -> Bool
- size :: FM k a -> Int
- member :: Ord k => k -> FM k a -> Bool
- count :: Ord k => k -> FM k a -> Int
- lookup :: Ord k => k -> FM k a -> a
- lookupM :: (Ord k, MonadFail m) => k -> FM k a -> m a
- lookupAll :: (Ord k, Sequence seq) => k -> FM k a -> seq a
- lookupAndDelete :: Ord k => k -> FM k a -> (a, FM k a)
- lookupAndDeleteM :: (Ord k, MonadFail m) => k -> FM k a -> m (a, FM k a)
- lookupAndDeleteAll :: (Ord k, Sequence seq) => k -> FM k a -> (seq a, FM k a)
- lookupWithDefault :: Ord k => a -> k -> FM k a -> a
- adjust :: Ord k => (a -> a) -> k -> FM k a -> FM k a
- adjustAll :: Ord k => (a -> a) -> k -> FM k a -> FM k a
- adjustOrInsert :: Ord k => (a -> a) -> a -> k -> FM k a -> FM k a
- adjustAllOrInsert :: Ord k => (a -> a) -> a -> k -> FM k a -> FM k a
- adjustOrDelete :: Ord k => (a -> Maybe a) -> k -> FM k a -> FM k a
- adjustOrDeleteAll :: Ord k => (a -> Maybe a) -> k -> FM k a -> FM k a
- strict :: Ord k => FM k a -> FM k a
- strictWith :: Ord k => (a -> b) -> FM k a -> FM k a
- map :: Ord k => (a -> b) -> FM k a -> FM k b
- fold :: Ord k => (a -> b -> b) -> b -> FM k a -> b
- fold' :: Ord k => (a -> b -> b) -> b -> FM k a -> b
- fold1 :: Ord k => (a -> a -> a) -> FM k a -> a
- fold1' :: Ord k => (a -> a -> a) -> FM k a -> a
- filter :: Ord k => (a -> Bool) -> FM k a -> FM k a
- partition :: Ord k => (a -> Bool) -> FM k a -> (FM k a, FM k a)
- elements :: (Ord k, Sequence seq) => FM k a -> seq a
- structuralInvariant :: Ord k => FM k a -> Bool
- fromSeqWith :: (Ord k, Sequence seq) => (a -> a -> a) -> seq (k, a) -> FM k a
- fromSeqWithKey :: (Ord k, Sequence seq) => (k -> a -> a -> a) -> seq (k, a) -> FM k a
- insertWith :: Ord k => (a -> a -> a) -> k -> a -> FM k a -> FM k a
- insertWithKey :: Ord k => (k -> a -> a -> a) -> k -> a -> FM k a -> FM k a
- insertSeqWith :: (Ord k, Sequence seq) => (a -> a -> a) -> seq (k, a) -> FM k a -> FM k a
- insertSeqWithKey :: (Ord k, Sequence seq) => (k -> a -> a -> a) -> seq (k, a) -> FM k a -> FM k a
- unionl :: Ord k => FM k a -> FM k a -> FM k a
- unionr :: Ord k => FM k a -> FM k a -> FM k a
- unionWith :: Ord k => (a -> a -> a) -> FM k a -> FM k a -> FM k a
- unionSeqWith :: (Ord k, Sequence seq) => (a -> a -> a) -> seq (FM k a) -> FM k a
- intersectionWith :: Ord k => (a -> b -> c) -> FM k a -> FM k b -> FM k c
- difference :: Ord k => FM k a -> FM k b -> FM k a
- properSubset :: Ord k => FM k a -> FM k b -> Bool
- subset :: Ord k => FM k a -> FM k b -> Bool
- properSubmapBy :: Ord k => (a -> a -> Bool) -> FM k a -> FM k a -> Bool
- submapBy :: Ord k => (a -> a -> Bool) -> FM k a -> FM k a -> Bool
- sameMapBy :: Ord k => (a -> a -> Bool) -> FM k a -> FM k a -> Bool
- properSubmap :: (Ord k, Eq a) => FM k a -> FM k a -> Bool
- submap :: (Ord k, Eq a) => FM k a -> FM k a -> Bool
- sameMap :: (Ord k, Eq a) => FM k a -> FM k a -> Bool
- minView :: (Ord k, MonadFail m) => FM k a -> m (a, FM k a)
- minElem :: Ord k => FM k a -> a
- deleteMin :: Ord k => FM k a -> FM k a
- unsafeInsertMin :: Ord k => k -> a -> FM k a -> FM k a
- maxView :: (Ord k, MonadFail m) => FM k a -> m (a, FM k a)
- maxElem :: Ord k => FM k a -> a
- deleteMax :: Ord k => FM k a -> FM k a
- unsafeInsertMax :: Ord k => k -> a -> FM k a -> FM k a
- foldr :: Ord k => (a -> b -> b) -> b -> FM k a -> b
- foldr' :: Ord k => (a -> b -> b) -> b -> FM k a -> b
- foldl :: Ord k => (b -> a -> b) -> b -> FM k a -> b
- foldl' :: Ord k => (b -> a -> b) -> b -> FM k a -> b
- foldr1 :: Ord k => (a -> a -> a) -> FM k a -> a
- foldr1' :: Ord k => (a -> a -> a) -> FM k a -> a
- foldl1 :: Ord k => (a -> a -> a) -> FM k a -> a
- foldl1' :: Ord k => (a -> a -> a) -> FM k a -> a
- unsafeFromOrdSeq :: (Ord k, Sequence seq) => seq (k, a) -> FM k a
- unsafeAppend :: Ord k => FM k a -> FM k a -> FM k a
- filterLT :: Ord k => k -> FM k a -> FM k a
- filterLE :: Ord k => k -> FM k a -> FM k a
- filterGT :: Ord k => k -> FM k a -> FM k a
- filterGE :: Ord k => k -> FM k a -> FM k a
- partitionLT_GE :: Ord k => k -> FM k a -> (FM k a, FM k a)
- partitionLE_GT :: Ord k => k -> FM k a -> (FM k a, FM k a)
- partitionLT_GT :: Ord k => k -> FM k a -> (FM k a, FM k a)
- toSeq :: (Ord k, Sequence seq) => FM k a -> seq (k, a)
- keys :: (Ord k, Sequence seq) => FM k a -> seq k
- mapWithKey :: Ord k => (k -> a -> b) -> FM k a -> FM k b
- foldWithKey :: Ord k => (k -> a -> b -> b) -> b -> FM k a -> b
- foldWithKey' :: Ord k => (k -> a -> b -> b) -> b -> FM k a -> b
- filterWithKey :: Ord k => (k -> a -> Bool) -> FM k a -> FM k a
- partitionWithKey :: Ord k => (k -> a -> Bool) -> FM k a -> (FM k a, FM k a)
- minViewWithKey :: (Ord k, MonadFail m) => FM k a -> m ((k, a), FM k a)
- minElemWithKey :: Ord k => FM k a -> (k, a)
- maxViewWithKey :: (Ord k, MonadFail m) => FM k a -> m ((k, a), FM k a)
- maxElemWithKey :: Ord k => FM k a -> (k, a)
- foldrWithKey :: (k -> a -> b -> b) -> b -> FM k a -> b
- foldrWithKey' :: (k -> a -> b -> b) -> b -> FM k a -> b
- foldlWithKey :: (b -> k -> a -> b) -> b -> FM k a -> b
- foldlWithKey' :: (b -> k -> a -> b) -> b -> FM k a -> b
- toOrdSeq :: (Ord k, Sequence seq) => FM k a -> seq (k, a)
- unionWithKey :: Ord k => (k -> a -> a -> a) -> FM k a -> FM k a -> FM k a
- unionSeqWithKey :: (Ord k, Sequence seq) => (k -> a -> a -> a) -> seq (FM k a) -> FM k a
- intersectionWithKey :: Ord k => (k -> a -> b -> c) -> FM k a -> FM k b -> FM k c
- moduleName :: String
Type of standard finite maps
AssocX operations
lookupWithDefault :: Ord k => a -> k -> FM k a -> a Source #
FiniteMapX operations
insertSeqWithKey :: (Ord k, Sequence seq) => (k -> a -> a -> a) -> seq (k, a) -> FM k a -> FM k a Source #
OrdAssocX operations
Assoc operations
foldWithKey :: Ord k => (k -> a -> b -> b) -> b -> FM k a -> b Source #
foldWithKey' :: Ord k => (k -> a -> b -> b) -> b -> FM k a -> b Source #
OrdAssoc operations
minElemWithKey :: Ord k => FM k a -> (k, a) Source #
maxElemWithKey :: Ord k => FM k a -> (k, a) Source #
foldrWithKey :: (k -> a -> b -> b) -> b -> FM k a -> b Source #
foldrWithKey' :: (k -> a -> b -> b) -> b -> FM k a -> b Source #
foldlWithKey :: (b -> k -> a -> b) -> b -> FM k a -> b Source #
foldlWithKey' :: (b -> k -> a -> b) -> b -> FM k a -> b Source #
FiniteMap operations
Documentation
moduleName :: String Source #
Orphan instances
Ord k => Assoc (FM k) k Source # | |
Methods toSeq :: Sequence seq => FM k a -> seq (k, a) # keys :: Sequence seq => FM k a -> seq k # mapWithKey :: (k -> a -> b) -> FM k a -> FM k b # foldWithKey :: (k -> a -> b -> b) -> b -> FM k a -> b # foldWithKey' :: (k -> a -> b -> b) -> b -> FM k a -> b # filterWithKey :: (k -> a -> Bool) -> FM k a -> FM k a # partitionWithKey :: (k -> a -> Bool) -> FM k a -> (FM k a, FM k a) # | |
Ord k => AssocX (FM k) k Source # | |
Methods singleton :: k -> a -> FM k a # fromSeq :: Sequence seq => seq (k, a) -> FM k a # insert :: k -> a -> FM k a -> FM k a # insertSeq :: Sequence seq => seq (k, a) -> FM k a -> FM k a # union :: FM k a -> FM k a -> FM k a # unionSeq :: Sequence seq => seq (FM k a) -> FM k a # delete :: k -> FM k a -> FM k a # deleteAll :: k -> FM k a -> FM k a # deleteSeq :: Sequence seq => seq k -> FM k a -> FM k a # member :: k -> FM k a -> Bool # lookupM :: MonadFail rm => k -> FM k a -> rm a # lookupAll :: Sequence seq => k -> FM k a -> seq a # lookupAndDelete :: k -> FM k a -> (a, FM k a) # lookupAndDeleteM :: MonadFail rm => k -> FM k a -> rm (a, FM k a) # lookupAndDeleteAll :: Sequence seq => k -> FM k a -> (seq a, FM k a) # lookupWithDefault :: a -> k -> FM k a -> a # adjust :: (a -> a) -> k -> FM k a -> FM k a # adjustAll :: (a -> a) -> k -> FM k a -> FM k a # adjustOrInsert :: (a -> a) -> a -> k -> FM k a -> FM k a # adjustAllOrInsert :: (a -> a) -> a -> k -> FM k a -> FM k a # adjustOrDelete :: (a -> Maybe a) -> k -> FM k a -> FM k a # adjustOrDeleteAll :: (a -> Maybe a) -> k -> FM k a -> FM k a # fold :: (a -> b -> b) -> b -> FM k a -> b # fold' :: (a -> b -> b) -> b -> FM k a -> b # fold1 :: (a -> a -> a) -> FM k a -> a # fold1' :: (a -> a -> a) -> FM k a -> a # filter :: (a -> Bool) -> FM k a -> FM k a # partition :: (a -> Bool) -> FM k a -> (FM k a, FM k a) # elements :: Sequence seq => FM k a -> seq a # strictWith :: (a -> b) -> FM k a -> FM k a # structuralInvariant :: FM k a -> Bool # instanceName :: FM k a -> String # | |
Ord k => FiniteMap (FM k) k Source # | |
Methods unionWithKey :: (k -> a -> a -> a) -> FM k a -> FM k a -> FM k a # unionSeqWithKey :: Sequence seq => (k -> a -> a -> a) -> seq (FM k a) -> FM k a # intersectionWithKey :: (k -> a -> b -> c) -> FM k a -> FM k b -> FM k c # | |
Ord k => FiniteMapX (FM k) k Source # | |
Methods fromSeqWith :: Sequence seq => (a -> a -> a) -> seq (k, a) -> FM k a # fromSeqWithKey :: Sequence seq => (k -> a -> a -> a) -> seq (k, a) -> FM k a # insertWith :: (a -> a -> a) -> k -> a -> FM k a -> FM k a # insertWithKey :: (k -> a -> a -> a) -> k -> a -> FM k a -> FM k a # insertSeqWith :: Sequence seq => (a -> a -> a) -> seq (k, a) -> FM k a -> FM k a # insertSeqWithKey :: Sequence seq => (k -> a -> a -> a) -> seq (k, a) -> FM k a -> FM k a # unionl :: FM k a -> FM k a -> FM k a # unionr :: FM k a -> FM k a -> FM k a # unionWith :: (a -> a -> a) -> FM k a -> FM k a -> FM k a # unionSeqWith :: Sequence seq => (a -> a -> a) -> seq (FM k a) -> FM k a # intersectionWith :: (a -> b -> c) -> FM k a -> FM k b -> FM k c # difference :: FM k a -> FM k b -> FM k a # properSubset :: FM k a -> FM k b -> Bool # subset :: FM k a -> FM k b -> Bool # submapBy :: (a -> a -> Bool) -> FM k a -> FM k a -> Bool # properSubmapBy :: (a -> a -> Bool) -> FM k a -> FM k a -> Bool # | |
Ord k => OrdAssoc (FM k) k Source # | |
Methods minViewWithKey :: MonadFail rm => FM k a -> rm ((k, a), FM k a) # minElemWithKey :: FM k a -> (k, a) # maxViewWithKey :: MonadFail rm => FM k a -> rm ((k, a), FM k a) # maxElemWithKey :: FM k a -> (k, a) # foldrWithKey :: (k -> a -> b -> b) -> b -> FM k a -> b # foldrWithKey' :: (k -> a -> b -> b) -> b -> FM k a -> b # foldlWithKey :: (b -> k -> a -> b) -> b -> FM k a -> b # foldlWithKey' :: (b -> k -> a -> b) -> b -> FM k a -> b # | |
Ord k => OrdAssocX (FM k) k Source # | |
Methods minView :: MonadFail rm => FM k a -> rm (a, FM k a) # deleteMin :: FM k a -> FM k a # unsafeInsertMin :: k -> a -> FM k a -> FM k a # maxView :: MonadFail rm => FM k a -> rm (a, FM k a) # deleteMax :: FM k a -> FM k a # unsafeInsertMax :: k -> a -> FM k a -> FM k a # foldr :: (a -> b -> b) -> b -> FM k a -> b # foldr' :: (a -> b -> b) -> b -> FM k a -> b # foldl :: (b -> a -> b) -> b -> FM k a -> b # foldl' :: (b -> a -> b) -> b -> FM k a -> b # foldr1 :: (a -> a -> a) -> FM k a -> a # foldr1' :: (a -> a -> a) -> FM k a -> a # foldl1 :: (a -> a -> a) -> FM k a -> a # foldl1' :: (a -> a -> a) -> FM k a -> a # unsafeFromOrdSeq :: Sequence seq => seq (k, a) -> FM k a # unsafeAppend :: FM k a -> FM k a -> FM k a # filterLT :: k -> FM k a -> FM k a # filterLE :: k -> FM k a -> FM k a # filterGT :: k -> FM k a -> FM k a # filterGE :: k -> FM k a -> FM k a # partitionLT_GE :: k -> FM k a -> (FM k a, FM k a) # partitionLE_GT :: k -> FM k a -> (FM k a, FM k a) # partitionLT_GT :: k -> FM k a -> (FM k a, FM k a) # | |
Ord k => OrdFiniteMap (FM k) k Source # | |
Ord k => OrdFiniteMapX (FM k) k Source # | |