RFR: JDK-8319123 : Implementation of JEP-461: Stream Gatherers (Preview) [v2]
Daniel Fuchs
dfuchs at openjdk.org
Thu Nov 9 11:51:11 UTC 2023
On Thu, 9 Nov 2023 09:34:26 GMT, Viktor Klang <vklang at openjdk.org> wrote:
>> I think it's still better to specify this for every method. Many developers read the documentation only for the specific method they are going to call, using IDE features like quick documentation.
>
> Yeah, I agree with @amaembo, I think it is important to keep the contract close to the caller.
I don't mind either way - just wanted to note that the notion of blanket statements for `NullPointerException` is used in several areas ([java.util.logging](https://docs.oracle.com/en/java/javase/21/docs/api/java.logging/java/util/logging/package-summary.html), [java.net.http](https://docs.oracle.com/en/java/javase/21/docs/api/java.net.http/java/net/http/package-summary.html) ...). So there is an established precedent if you were inclined to go this route.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/16420#discussion_r1387889210
More information about the core-libs-dev
mailing list