code: public static <V, C extends Collection<Node<V>>> C collectNodes(Node<V> parent,
                                                                      Predicate<Node<V>> predicate,
                                                                      C collection) {
          checkArgNotNull(predicate, "predicate");
          checkArgNotNull(collection, "collection");
          return parent != null && hasChildren(parent) ?
                  collectNodes(parent.getChildren(), predicate, collection) : collection;
      }
docs: Collects all nodes underneath the given parent for which the given predicate evaluates to true.
  
  @param parent     the parent Node
  @param predicate  the predicate
  @param collection the collection to collect the found Nodes into
  @return the same collection instance passed as a parameter