filteredNode.setParentFunction( ReflectionFunctions.createInvokeMethod("getParent"));
filteredNode.setChildrenFunction( FunctionFactory.concatenation(
ReflectionFunctions.createInvokeMethod("children"),
new EnumerationWithFilterFunction<TreeNode>(childAllowedFunction, context),
//new ToListFunction<TreeNode>(),
new CollectionFunctions(CollectionFunctions.Operation.toIterator),
new ModifyingFunction(ModifyingFunction.Operation.iterate, new TreeNodeFactory(TreeNodeOperation.createChildrenFilteringTreeNode, childAllowedFunction)),
new CollectionFunctions(CollectionFunctions.Operation.toList)
));
filteredNode.setUserObject(rootNode);
return filteredNode;