mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
8242281: IntStream.html#reduce doc should not mention average
Remove mention of average function in apiNote of IntStream::reduce(int, IntBinaryOperator) Reviewed-by: psandoz, jlaskey, lancea, dfuchs
This commit is contained in:
parent
f7a65b7fff
commit
22532ff30e
1 changed files with 4 additions and 3 deletions
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2012, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -474,8 +474,9 @@ public interface IntStream extends BaseStream<Integer, IntStream> {
|
||||||
* <p>This is a <a href="package-summary.html#StreamOps">terminal
|
* <p>This is a <a href="package-summary.html#StreamOps">terminal
|
||||||
* operation</a>.
|
* operation</a>.
|
||||||
*
|
*
|
||||||
* @apiNote Sum, min, max, and average are all special cases of reduction.
|
* @apiNote Sum, min and max are all special cases of reduction that can be
|
||||||
* Summing a stream of numbers can be expressed as:
|
* expressed using this method.
|
||||||
|
* For example, summing a stream can be expressed as:
|
||||||
*
|
*
|
||||||
* <pre>{@code
|
* <pre>{@code
|
||||||
* int sum = integers.reduce(0, (a, b) -> a+b);
|
* int sum = integers.reduce(0, (a, b) -> a+b);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue