JBIterable<T> childrenImpl(@Nullable T node,
                               @NotNull Function<? super T, ? extends Iterable<? extends T>> tree) {
      if (node == null) {
        return JBIterable.empty();
      }
      else if (expand != Cond.TRUE && !expand.valueAnd(node) &&
               (forceExpand == Cond.FALSE || !forceExpand.valueOr(node))) {
        return JBIterable.empty();
      }
      else {
        if (regard == Cond.TRUE && forceDisregard == Cond.FALSE) {
          return JBIterable.<T>from(tree.fun(node)).filter(not(forceIgnore.or()));
        }
        else {
          // traverse subtree to select accepted children
          return TreeTraversal.GUIDED_TRAVERSAL(createChildrenGuide(node)).traversal(node, tree);
        }
      }
    }
JBIterable<T> childrenImpl(@Nullable T node,
                               @NotNull Function<? super T, ? extends Iterable<? extends T>> tree)