This structure contains functions for pruning trees by a predicate.
List of Import References :
See BOOL
See BSTree
See DENOTATION
See Nat
See Option
See Pair
See Seq
See Tree
SIGNATURE BSTreeFilter[data, <]
$Date: 2010-09-30 18:24:17 +0200 (Do, 30. Sep 2010) $ ($Revision: 616 $)
IMPORT BSTree[data, <] ONLY bstree[data, <]
SORT data FUN < : data ** data -> bool
take(P, t)
removes all subtrees from t
whose values
do not fulfill P
.
FUN take: (data -> bool) ** bstree -> bstree
drop
removes the leaves which do fulfill the given
predicate. dropall
does this repeatedly.
FUN drop: (data -> bool) ** bstree -> bstree FUN dropall: (data -> bool) ** bstree -> bstree
next node: BSTreeIndex,
prev node: BSTreeConv,
up to node: Subsystem Balanced Search Trees