public static <C extends Comparable<? super C>>
	Collector<C, ?, MinMax<C>> toMinMax() {
		return toMinMax(Comparator.naturalOrder());
	}
public static < C extends Comparable < ? super C > > Collector < C , ? , MinMax < C > > toMinMax ( ) { return toMinMax ( Comparator . naturalOrder ( ) ) ; }
Return a {@code Collector} which calculates the minimum and maximum value.
The <i>reducing</i> objects must be comparable.

<pre>{@code
final Stream<SomeObject> stream = ...
final MinMax<SomeObject> moments = stream
.collect(doubleMoments.toMinMax(comparator));
}</pre>

@param <C> the type of the input elements
@return a {@code Collector} implementing the min-max reduction
@throws java.lang.NullPointerException if the given {@code mapper} is
{@code null}