pred-trie-0.5.1: Predicative tries

Safe HaskellNone
LanguageHaskell2010

Data.Trie.Pred.Mutable

Contents

Synopsis

Tail

data PredStep s k r Source

Constructors

forall a . Typeable a => PredStep 

Fields

predPred :: !(PredKey s k a)
 
predData :: !(Maybe (a -> r))
 
predSub :: !(HashTableTrie s k (a -> r))
 

data RawValue s k a Source

Constructors

RawValue 

Fields

rawValue :: !(Maybe a)
 
rawChildren :: !(HashTableTrie s k a)
 

data HashTableTrie s k a Source

Constructors

HashTableTrie 

Fields

rawValues :: !(HashTable s k (RawValue s k a))
 
predPreds :: [PredStep s k a]
 

new :: ST s (HashTableTrie s k a) Source

insert :: (Eq k, Hashable k) => NonEmpty k -> a -> HashTableTrie s k a -> ST s (HashTableTrie s k a) Source

lookup :: (Eq k, Hashable k, Typeable s, Typeable k) => PredSet s k -> NonEmpty k -> HashTableTrie s k a -> ST s (Maybe a) Source

match :: (Eq k, Hashable k, Typeable s, Typeable k) => PredSet s k -> NonEmpty k -> HashTableTrie s k a -> ST s (Maybe (NonEmpty k, a, [k])) Source

matches :: (Eq k, Hashable k, Typeable s, Typeable k) => PredSet s k -> NonEmpty k -> HashTableTrie s k a -> ST s [(NonEmpty k, a, [k])] Source

Rooted

data RootedHashTableTrie s k a Source

Constructors

RootedHashTableTrie 

Fields

rootedBase :: !(Maybe a)
 
rootedSub :: !(HashTableTrie s k a)
 
rootedPredSet :: !(PredSet s k)
 

lookupR :: (Eq k, Hashable k, Typeable s, Typeable k, Typeable a) => [k] -> RootedHashTableTrie s k a -> ST s (Maybe a) Source

matchR :: (Eq k, Hashable k, Typeable s, Typeable k, Typeable a) => [k] -> RootedHashTableTrie s k a -> ST s (Maybe ([k], a, [k])) Source

matchesR :: (Eq k, Hashable k, Typeable s, Typeable k, Typeable a) => [k] -> RootedHashTableTrie s k a -> ST s [([k], a, [k])] Source