Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- class MVector (Mutable v) a ⇒ Vector (v ∷ Type → Type) a
- type VB = Vector
- type VU = Vector
- type VP = Vector
- type VS = Vector
- newtype VMap kv vv k v = VMap {}
- empty ∷ (Vector kv k, Vector vv v) ⇒ VMap kv vv k v
- size ∷ Vector kv k ⇒ VMap kv vv k v → Int
- lookup ∷ (Ord k, Vector kv k, Vector vv v) ⇒ k → VMap kv vv k v → Maybe v
- findWithDefault ∷ (Ord k, Vector kv k, Vector vv v) ⇒ v → k → VMap kv vv k v → v
- member ∷ (Ord k, Vector kv k) ⇒ k → VMap kv vv k v → Bool
- notMember ∷ (Ord k, Vector kv k) ⇒ k → VMap kv vv k v → Bool
- map ∷ (Vector vv a, Vector vv b) ⇒ (a → b) → VMap kv vv k a → VMap kv vv k b
- mapMaybe ∷ (Vector kv k, Vector vv a, Vector vv b) ⇒ (a → Maybe b) → VMap kv vv k a → VMap kv vv k b
- mapWithKey ∷ (Vector kv k, Vector vv a, Vector vv b) ⇒ (k → a → b) → VMap kv vv k a → VMap kv vv k b
- filter ∷ (Vector kv k, Vector vv v) ⇒ (k → v → Bool) → VMap kv vv k v → VMap kv vv k v
- fold ∷ (Vector vv m, Monoid m) ⇒ VMap kv vv k m → m
- foldl ∷ Vector vv v ⇒ (a → v → a) → a → VMap kv vv k v → a
- foldlWithKey ∷ (Vector kv k, Vector vv v) ⇒ (a → k → v → a) → a → VMap kv vv k v → a
- foldMap ∷ (Vector vv v, Monoid m) ⇒ (v → m) → VMap kv vv k v → m
- foldMapWithKey ∷ (Vector kv k, Vector vv v, Monoid m) ⇒ (k → v → m) → VMap kv vv k v → m
- fromMap ∷ (Vector kv k, Vector vv v) ⇒ Map k v → VMap kv vv k v
- toMap ∷ (Vector kv k, Vector vv v) ⇒ VMap kv vv k v → Map k v
- fromList ∷ (Ord k, Vector kv k, Vector vv v) ⇒ [(k, v)] → VMap kv vv k v
- fromListN ∷ (Ord k, Vector kv k, Vector vv v) ⇒ Int → [(k, v)] → VMap kv vv k v
- toList ∷ (Vector kv k, Vector vv v) ⇒ VMap kv vv k v → [(k, v)]
- toAscList ∷ (Vector kv k, Vector vv v) ⇒ VMap kv vv k v → [(k, v)]
- keys ∷ Vector kv k ⇒ VMap kv vv k v → [k]
- elems ∷ Vector vv v ⇒ VMap kv vv k v → [v]
- fromAscList ∷ (Eq k, Vector kv k, Vector vv v) ⇒ [(k, v)] → VMap kv vv k v
- fromAscListN ∷ (Eq k, Vector kv k, Vector vv v) ⇒ Int → [(k, v)] → VMap kv vv k v
- fromAscListWithKey ∷ (Eq k, Vector kv k, Vector vv v) ⇒ (k → v → v → v) → [(k, v)] → VMap kv vv k v
- fromAscListWithKeyN ∷ (Eq k, Vector kv k, Vector vv v) ⇒ Int → (k → v → v → v) → [(k, v)] → VMap kv vv k v
- fromDistinctAscList ∷ (Vector kv k, Vector vv v) ⇒ [(k, v)] → VMap kv vv k v
- fromDistinctAscListN ∷ (Vector kv k, Vector vv v) ⇒ Int → [(k, v)] → VMap kv vv k v
- internMaybe ∷ (Vector kv k, Ord k) ⇒ k → VMap kv vv k v → Maybe k
- null ∷ (Vector vv v, Vector kv k) ⇒ VMap kv vv k v → Bool
- splitAt ∷ (Vector vv v, Vector kv k) ⇒ Int → VMap kv vv k v → (VMap kv vv k v, VMap kv vv k v)
- data KVMVector kmv vmv s a
- data KVVector kv vv a
- normalize ∷ (Vector kv k, Vector vv v, Ord k) ⇒ KVVector kv vv (k, v) → KVVector kv vv (k, v)
- normalizeM ∷ (Ord k, PrimMonad m, Vector kv k, Vector vv v) ⇒ KVMVector (Mutable kv) (Mutable vv) (PrimState m) (k, v) → m (KVMVector (Mutable kv) (Mutable vv) (PrimState m) (k, v))
Documentation
class MVector (Mutable v) a ⇒ Vector (v ∷ Type → Type) a Source #
Class of immutable vectors. Every immutable vector is associated with its
mutable version through the Mutable
type family. Methods of this class
should not be used directly. Instead, Data.Vector.Generic and other
Data.Vector
modules provide safe and fusible wrappers.
Minimum complete implementation:
Instances
newtype VMap kv vv k v Source #
Instances
(Vector vk k, Vector vv v, Ord k, FromJSONKey k, FromJSON v) ⇒ FromJSON (VMap vk vv k v) Source # | |
(Vector vk k, Vector vv v, ToJSONKey k, ToJSON v) ⇒ ToJSON (VMap vk vv k v) Source # | |
(Vector kv k, Vector vv v, Ord k) ⇒ Monoid (VMap kv vv k v) Source # | |
(Vector kv k, Vector vv v, Ord k) ⇒ Semigroup (VMap kv vv k v) Source # | |
(Vector kv k, Vector vv v, Ord k) ⇒ IsList (VMap kv vv k v) Source # | |
Generic (VMap kv vv k v) Source # | |
(Show k, Show v, Vector kv k, Vector vv v) ⇒ Show (VMap kv vv k v) Source # | |
(NFData (kv k), NFData (vv v)) ⇒ NFData (VMap kv vv k v) Source # | |
(Eq (kv k), Eq (vv v)) ⇒ Eq (VMap kv vv k v) Source # | |
(NoThunks (kv k), NoThunks (vv v), Typeable kv, Typeable vv, Typeable k, Typeable v) ⇒ NoThunks (VMap kv vv k v) Source # | |
type Item (VMap kv vv k v) Source # | |
type Rep (VMap kv vv k v) Source # | |
mapMaybe ∷ (Vector kv k, Vector vv a, Vector vv b) ⇒ (a → Maybe b) → VMap kv vv k a → VMap kv vv k b Source #
mapWithKey ∷ (Vector kv k, Vector vv a, Vector vv b) ⇒ (k → a → b) → VMap kv vv k a → VMap kv vv k b Source #
fromAscListWithKey ∷ (Eq k, Vector kv k, Vector vv v) ⇒ (k → v → v → v) → [(k, v)] → VMap kv vv k v Source #
fromAscListWithKeyN ∷ (Eq k, Vector kv k, Vector vv v) ⇒ Int → (k → v → v → v) → [(k, v)] → VMap kv vv k v Source #
splitAt ∷ (Vector vv v, Vector kv k) ⇒ Int → VMap kv vv k v → (VMap kv vv k v, VMap kv vv k v) Source #
data KVMVector kmv vmv s a Source #
Instances
(MVector kmv k, MVector vmv v) ⇒ MVector (KVMVector kmv vmv) (k, v) Source # | |
Defined in Data.VMap.KVVector basicLength ∷ KVMVector kmv vmv s (k, v) → Int Source # basicUnsafeSlice ∷ Int → Int → KVMVector kmv vmv s (k, v) → KVMVector kmv vmv s (k, v) Source # basicOverlaps ∷ KVMVector kmv vmv s (k, v) → KVMVector kmv vmv s (k, v) → Bool Source # basicUnsafeNew ∷ Int → ST s (KVMVector kmv vmv s (k, v)) Source # basicInitialize ∷ KVMVector kmv vmv s (k, v) → ST s () Source # basicUnsafeReplicate ∷ Int → (k, v) → ST s (KVMVector kmv vmv s (k, v)) Source # basicUnsafeRead ∷ KVMVector kmv vmv s (k, v) → Int → ST s (k, v) Source # basicUnsafeWrite ∷ KVMVector kmv vmv s (k, v) → Int → (k, v) → ST s () Source # basicClear ∷ KVMVector kmv vmv s (k, v) → ST s () Source # basicSet ∷ KVMVector kmv vmv s (k, v) → (k, v) → ST s () Source # basicUnsafeCopy ∷ KVMVector kmv vmv s (k, v) → KVMVector kmv vmv s (k, v) → ST s () Source # basicUnsafeMove ∷ KVMVector kmv vmv s (k, v) → KVMVector kmv vmv s (k, v) → ST s () Source # basicUnsafeGrow ∷ KVMVector kmv vmv s (k, v) → Int → ST s (KVMVector kmv vmv s (k, v)) Source # |
data KVVector kv vv a Source #