(index ("make-suffix-tree" 0))
(def (sig (procedure "make-suffix-tree:: LEQ? KEY->LIST -> SELECTOR" (id make-suffix-tree))) (p "where:") (ul (li (tt "LEQ?") " is a less-than-or-equal procedure for comparing elements of the member lists") (li "{{KEY->LIST} is a procedure that takes in a key value and returns a list")) (p "The returned selector procedure can take one of the following arguments:") (dl (dt (tt "'insert")) (dd "inserts a new element (list); a procedure of the form " (tt "(LAMBDA (K BVAL) ...)") " where " (tt "K") " is a value of the type recognized by " (tt "KEY->LIST") " and " (tt "BVAL") " is the end-of-list value") (dt (tt "'lookup")) (dd "looks up an element (list); a procedure of the form " (tt "(LAMBDA (K) ...)") " where " (tt "K") " is a value of the type recognized by " (tt "KEY->LIST") "; returns the EOL value or " (tt "#F") " if the given element is not found") (dt (tt "'lookup/partial")) (dd "partial lookup; returns the EOL value, " (tt "#f") " or the subtree that corresponds to the given partial key") (dt (tt "'remove")) (dd "removes an element") (dt (tt "'merge")) (dd "merges the suffix tree with another; if there is a list that appears in both suffix trees, an exception is raised") (dt (tt "'partition")) (dd "splits the tree into three suffix-trees on the basis of the given element a.  The first suffix-tree consists of branches with keys less than a (plus any EOL value), the second contains the branch (if any) associated with a, and the third consists of branches for keys greater than a")))
