FluentIterable implements Iterable<Q> { public static <T> FluentIterable<T> from(@Nonnull Iterable<T> from) { return new FluentIterable<T>(checkNotNull(from, "Source can not be null")); } private  FluentIterable(@Nullable Iterable<Q> source); @Override Iterator<Q> iterator(); static FluentIterable<T> from(@Nonnull Iterable<T> from); @SuppressWarnings("unchecked") final FluentIterable<T> filter(final Class<T> type); FluentIterable<Q> filter(final Predicate<? super Q> predicate); FluentIterable<V> transform(final Function<? super Q, ? extends V> function); List<Q> toList(); Set<Q> toSet(); Optional<Q> first(); Optional<Q> firstMatch(Predicate<Q> predicate); int size();  }
@Test(expectedExceptions = NullPointerException.class) public void filter_from_null_collection_throws_NPE() throws Exception { from(null); }