static void checkNoneNull(Iterable<?> objects) {
    if (!(objects instanceof ImmutableCollection)) {
      for (Object o : objects) {
        checkNotNull(o);
      }
    }
  }
Checks that no element in the given iterable is null, throwing NPE if any is.
jimfs/src/main/java/com/google/common/jimfs/Util.java