public BiStream < T , U > throwIfNull ( BiPredicate < ? super T , ? super U > biPredicate , Supplier < ? extends RuntimeException > e ) { Predicate < T > predicate = ( t ) - > biPredicate . test ( t , object ) ; return nonEmptyStream ( stream . filter ( predicate ) , e ) ; }
Compares the objects from stream to the injected object . If the rest of the stream equals null so exception is thrown .