public static <E> Iterator<E> filter(Iterable<E> iterable, Predicate<E> predicate) {
        dbc.precondition(iterable != null, "cannot call filter with a null iterable");
        return filter(iterable.iterator(), predicate);
    }
public static < E > Iterator < E > filter ( Iterable < E > iterable , Predicate < E > predicate ) { dbc . precondition ( iterable != null , "cannot call filter with a null iterable" ) ; return filter ( iterable . iterator ( ) , predicate ) ; }
Creates an iterator yielding elements from the source iterable matching
the given predicate. This transformation is applied lazily and the
predicate is applied while consuming returned iterator. E.g:
<code>filter([1,2,3,4], isEven) -> [2,4]</code>

@param <E> the iterable element type
@param iterable the iterable where elements are fetched from
@param predicate the predicate applied to each element
@return an iterator containing the elements for which the predicate
evaluates to true