caesar0301/treelib

Limit contains method to a set depth

golharam opened this issue · 0 comments

Right now, I see .contains() on the tree will search the tree for a given node. Suppose I only want to search the immediate children of a node? Based on what I can tell, I have to get the children of the node, then iterate over them to find the matching child, if any. It would be nice to have a depth option on .contains() or a .find() method on a Node to search the immediate children.