public bool VisitEnter(Composite composite)
        {
            VisitCount++;

            Treenode node = (Treenode)composite;
            if (predicate(node) && node != lastResult) {
                lastResult = result = node;
            }
            return true;
        }
        public bool VisitExit(Composite composite)
        {
            bool val = result == null;

            return val;
        }