Searches the tree for a child that satisfies childMatchesroot the root of the tree
getChildren must return the set of children for the current node.
childMatches is called on each node in the tree. As soon as childMatches
returns true then the search is terminated and the current node is returned.