Open
Description
openedon Jul 25, 2018
AbstractSequentialIterator
is very rarely used, but we could still consider this helper, which might encourage more people to use it by permitting lambda expressions:
guava/guava/src/com/google/common/collect/RegularContiguousSet.java
Lines 80 to 87 in 34c1616
...becomes...
C last = last();
return AbstractSequentialIterator.of(
first(),
previous -> equalsOrThrow(previous, last) ? null : domain.next(previous));
But I guess I'm not really that excited about that particular example. And I'm not sure what the best method name would be.
This is similar to #2785, where I apparently excluded all Abstract*
classes, and #2853.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment