public <O> int foreach(Function<? super T, O> function) {
        int count = 0;
        for (T item : each()) {
        	function.apply(item);
            ++count;
		}
        
        return count;
    }
public < O > int foreach ( Function < ? super T , O > function ) { int count = 0 ; for ( T item : each ( ) ) { function . apply ( item ) ; ++ count ; } return count ; }
Invokes a function on each element of the delegate, ignoring the return value;
returns the number of elements that were present.