v      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstu(C) 2016 Rev. Johnny HealeyLGPL-3'Rev. Johnny Healey <rev.null@gmail.com> experimentalunknownSafe  is a paramorphism F-Algebra. is a catamorphism F-Algebra. is an anamorpism F-Algebra.P is a type for creating an in-memory representation of the fixed point of a v.6 is a typeclass for representing the fixed point of a v!. A well-behaved instance of 3 should not change the shape of the underlying v.5In other words, the following should always be true:   ( x) == x  N applies an AnaAlg over an argument to produce a fixed-point of a Functor.   applies a  over a fixed point of a v.   applies a  over a fixed point of a v.   maps from a fixed point of a v, to a different fixed point of the same v,. For any two well-behaved instances of , the shape of the v should remain unchanged. w    w(C) 2016 Rev. Johnny HealeyLGPL-3'Rev. Johnny Healey <rev.null@gmail.com> experimentalunknownNone&+034579>ILN A  G is a handle for accessing a file-backed recursive data structure. r is the  object stored in the  .A [ is an isolated execution of a read or update operation on the root object stored in a  . r is the  data that is stored by the  . s# is a phantom type used to isolate 2 values to the transaction where they are run.A  is a reference to a v f in the  instance of g.This is an instance of  and acts to bridge between the 8 and the recursively defined data structure that is (g f).A + is a datastructure that is an instance of  and x9. This acts as a sort of "header" for the file where the  may have several s under it to different Functors. is a class based on Traverse$ but taking an argument of kind (* -> *) -> *) instead of *. Given a function that maps from a to b over  g in the y f, traverse over t- changing the fixed-point combinator from a to b..A Constraint for data that can be used with a A  points to a location in a  # and has a phantom type for a v f. A & expects an argument that resembles a , but we can pass it a $ instead. This is not a well-formed ' because it can't be unpacked into f ( f).*But, it can be serialized, which allows a < object that takes this as an argument to be serialized. is a fixed-point combinator of f in Transaction s.zA memory-only instance of a.{An instance of a that is file-backed.|_Write the stored data to disk so that the on-disk representation matches what is in memory.,Lens for accessing the value stored in a Ref Perform a  on a part of the root object.1The preferred way to modify the root object of a   is by using <. It applies a function that takes the root object as a  s f7 and returns the new desired head of the same type.!The preferred way to read from a   is to use ). It applies a function that takes a  s f and returns a value. Create a  , using  fD as the initial structure to store at the location described by }. Create a  , using  fD as the initial structure to store at the location described by } and using the ~ to the file to be created.Open a   from the file described by }.Open a   from the file described by } and using the ~ to the file. Close a  Q. This can potentially cause errors on data that is lazily being read from a .! Perform a read transaction on a  . This transaction cannot modify the root object stored in the file. The returned value is lazily evaluated, but will always correspond to the root object at the start of the transaction."!Perform a write transaction on a  . This operation differs from the readTransaction in that the root object stored in the file can potentially be updated by this .#The # function behaves like ", but applies to a  wrapped in <. In the event that an exception propagates through the ,, the updates are not committed to disk.2This is meant to provide a mechanism for aborting s.$3Get the root datastructure from the transaction as r .%5Get the full datastructure from the transaction as a  f.& Because a  C is backed by an append-only file, there is a periodic need to & the file to garbage collect data that is no longer referenced from the root. This task operates on a temporary file that then replaces the file that backs FixFile.kThe memory usage of this operation scales with the recursive depth of the structure stored in the file.E z{| !"#$%&'  !"#$%&'    &!"#$%: z{| !"#$%&(C) 2016 Rev. Johnny HealeyLGPL-3'Rev. Johnny Healey <rev.null@gmail.com> experimentalunknownNone(+-./0>'A  (' n k v)( stores a BTree of key/value pairs. n should be a F and will be the maximum number of elements in each branch of the '.(Compute the depth of a ' ) An empty ' * Create a   storing a (' k v). The initial value is ).+Open a   storing a (' k v).,Insert the value v with the key k into a  (' k v).- version of ,..%Lookup the values stored for the key k in a  (' k v)./ version of ..0Filter items from a  (' k v) for a key k that match the predicate.1 version of 0.2Delete all items for key k from the  (' k v).3 version of 2.4Split a ' into two two ' s with keys  'k'and keys k.5Turn a  (' k v)! into a list of key value tuples.6'Turn a list of key value tuples into a  (' k v).&'()*+,-./0123456'()*+,-./0123456'*+)(,-./0123456'()*+,-./0123456(C) 2016 Rev. Johnny HealeyLGPL-3'Rev. Johnny Healey <rev.null@gmail.com> experimentalunknownNone+-./0 7A  (7 i)0 is a set of items represented as a binary tree.8 An empty 7.9Insert an item i into a  recursive 7 i.: version of 9.;Delete an item i into a  recursive 7 i.< version of ;.=#Predicate to lookup an item from a 7 i.> FTransaction version of =.? Create a   (7 i).@Open a   (7 i).ATurn a  recurive structure of 7 i into a list.B version of A.789:;<=>?@AB 789:;<=>?@AB 7?@89:;<=>AB789:;<=>?@AB(C) 2016 Rev. Johnny HealeyLGPL-3'Rev. Johnny Healey <rev.null@gmail.com> experimentalunknownNone +-./0345>L$CA C of keys k to values v! represented as a Two-Three Tree.DA D of k! represented as a Two-Three Tree.E (E d), represents a Two-Three tree. The data type d should have data families for it's key and value. These data families are not exported from the module. As a result, the only valid types for d are (D k) as defined here or (C k v), also defined here.F An empty  E.G9Predicate that returns true if there are no items in the E.HNumber of entries in (E g d).I The depth of (E g d). 0 represents en empty Tree.JInsert an item into a set.KLookup an item in a set.LDelete an item from a set.MSplit a set into sets of items  kand= kN#Convert a set into a list of items.O#Convert a list of items into a set.P Create a   for storing a set of items.QOpen a   for storing a set of items.R version of J.S FTransaction version of K.T FTransaction version of L.U version of M.V Insert value v into a map for key k!. Any existing value is replaced.W-Lookup an item in a map corresponding to key k.X!Delete an item from a map at key k.Y'Apply a function to alter a Map at key k. The function takes ( v)> as an argument for any possible exiting value and returns Nothing to delete a value or Just v to set a new value.ZSplit a set into maps for keys  kand= k[.Convert a map into a list of key-value tuples.\-Convert a lst of key-value tuples into a map.]!Return the list of keys in a map.^!Return a list of values in a map._Map a function over a map. Because of the way Tree23 is implemented, it is not possible to create a Functor instance to achieve this.` Create a   of a Map.aOpen a   of a Map.b version of V.c version of W.d version of X.e version of Z.f FTransaction version of Y.MCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefg%CDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefg%EFGHIDPQJKLMNORSTUC`aVWXZY_[\bcdef]^g:CDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefg(C) 2016 Rev. Johnny HealeyLGPL-3'Rev. Johnny Healey <rev.null@gmail.com> experimentalunknownNone +-./0>Lh (h v) is a trie mapping lazy  ByteStrings to values of type v.i An empty hjj takes a hp that has been mutated and creates a copy of it that allows for faster lookups. This happens automatically for hs that are serialized to a  . A h< will be automatically thawed on any node that is modified.k Create a   of (h v) data.lOpen a   of (h v) data.m5Lookup a possible value stored in a trie for a given  ByteString key.n version of m.o)Insert a value into a trie for the given  ByteString key.p version of o.q'Delete a value from a trie for a given  ByteString key.r version of q.s#Iterate over a Trie for all of the  ByteString and value tuples for a given  ByteString prefix.t version of s.uMap a function over a  hD. Because of the data types used, this can't be implemented as a v.#hijklmnopqrstuhijklmnopqrstuhijklmnopqrstuhijklmnopqrstu      !"#$%&'()*+,-./0123456789:;<=/>?@ABCDEFGH=I/JK.>B@LFMDE?CANOPQRSTUVWXYZ[\]^_`a/bcdefghijklmnopqrstnouvwxnyzn{|}~nnofixfi_A5vnY32sX9R79f6gJ3IHGA Data.FixFileData.FixFile.BTreeData.FixFile.SetData.FixFile.Tree23Data.FixFile.TrieData.FixFile.FixedParaAlgCataAlgAnaAlgFixInFoutFFixedinfoutfanacataparaisoFixFile TransactionRefdeRefRoot FixTraverse sequenceAFixFixablePtrStoredrefsubTransactionalterTlookupT createFixFilecreateFixFileHandle openFixFileopenFixFileHandle closeFixFilereadTransactionwriteTransactionwriteExceptTransactiongetRootgetFullvacuumBTreedepthemptycreateBTreeFile openBTreeFile insertBTree insertBTreeT lookupBTree lookupBTreeT filterBTree filterBTreeT deleteBTree deleteBTreeTpartitionBTree toListBTree fromListBTreeSet insertSet insertSetT deleteSet deleteSetT lookupSet lookupSetT createSetFile openSetFile toListSet toListSetTMapTree23nullsize partitionSet fromListSet partitionSetT insertMap lookupMap deleteMapalterMap partitionMap toListMap fromListMapkeysMap valuesMapmapMap createMapFile openMapFile insertMapT lookupMapT deleteMapT partitionMapT alterMapTpartitionTree23TriefreezecreateTrieFile openTrieFile lookupTrie lookupTrieT insertTrie insertTrieT deleteTrie deleteTrieT iterateTrie iterateTrieTtrieMapbaseGHC.BaseFunctor $fFixedFixbinar_3uXFWMoAGBg0xKP9MHKRwiData.Binary.ClassBinary ApplicativeMemoryCachedsyncGHC.IOFilePathGHC.IO.Handle.TypesHandletrans_GZTjP9K5WFq01xC9BAGQpFControl.Monad.Trans.ExceptExceptTrunRTFFHPosCachesCache HashTable createCache cacheInsert cacheLookupgetCachedOrStored withCache withCache_ getRawBlockgetBlock putRawBlockputBlockreadRoot writeRootrootIso withHandlereadStoredLazyacquireWriteLockreleaseWriteLock withWriteLock readHeader updateHeader$fMonadStaterTransaction$fMonadTransaction$fApplicativeTransaction$fFunctorTransaction$fFixTraverseRef $fBinaryRef $fHashablePtr $fBinaryPtr $fFixedStored GHC.TypeLitsNatPartedNoPartSkewDirLRDeleted AllDeleted UnChangedInsertInsertedSplitEmptyValueNodevaluenode treeNodeSize splitRangesplit3 $fBinaryBTree $fBinarySetMaybe Partition NoPartitionSkewSplit2ChangeNoChangeChanged UnbalancedHole TreeValueTreeKeyTree23FLeafTwoThreeMVfromMVMKSVSKleaftwothree lookupTree23 alterTree23merge$fBinaryTreeValue$fBinaryTreeKeyTFCo:R:TreeValueMapTFCo:R:TreeKeyMap$fBinaryTreeValue0$fBinaryTreeKey0TFCo:R:TreeValueSetTFCo:R:TreeKeySet$fBinaryTree23FNoDeleteTailStringSmallBigMutabletailstringfillsmallbigmut bigThresholdfreeze'thawsplitKey $fBinaryTrie