Class DFSFilteringIterator<E extends Element>

  • All Implemented Interfaces:
    Iterator<E>

    @Deprecated
    public class DFSFilteringIterator<E extends Element>
    extends Object
    implements Iterator<E>
    Deprecated.
    This always had very limited utility and Element.stream(Class, boolean) seems to be a more usable alternative.
    Recursively walks an element forest in a depth-first manner leaving out elements not matching the optionally provided filter.
    Since:
    0.1
    Author:
    Lukas Krejci
    • Constructor Detail

      • DFSFilteringIterator

        public DFSFilteringIterator​(@Nonnull
                                    Iterator<? extends Element> rootIterator,
                                    @Nonnull
                                    Class<? extends E> resultClass,
                                    @Nullable
                                    Filter<? super E> filter)
        Deprecated.
        Constructor.
        Parameters:
        rootIterator - the iterator over the root elements of the forest
        resultClass - the class of the elements to look for in the forest. All the returned elements will be assignable to this class.
        filter - optional filter that further filters out unwanted elements.