/** * Attaches a stage that emits just the items that are distinct according * to their definition of equality ({@code equals} and {@code hashCode}). * There is no guarantee which one of equal items it will emit. * * @return the newly attached stage */ @Nonnull default BatchStage<T> distinct() { return groupingKey(wholeItem()).distinct(); }