Optional.or name Re: RFR 8080418 Add Optional.or() (original) (raw)
Stephen Colebourne scolebourne at joda.org
Wed Oct 14 09:33:43 UTC 2015
- Previous message: Optional.or name Re: RFR 8080418 Add Optional.or()
- Next message: JDK 9 RFR of JDK-8139407: Mark java/rmi/registry/readTest/readTest.sh as intermittently failing
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Maybe "an optional equivalent to {@code this}"
The original text is quite obtuse.
Stephen
On 14 October 2015 at 09:54, Paul Sandoz <paul.sandoz at oracle.com> wrote:
On 13 Oct 2015, at 22:43, Stephen Colebourne <scolebourne at joda.org> wrote:
I'd prefer to see "this" mentioned: "If a value is not present, invoke the specified supplier to provide the result, otherwise return {@code this}" While I understand the original form gave some spec wiggle room, it also made the method far more mysterious. That wiggle room is useful to avoid baking in any assumptions about the identity of the returned Optional. Paul.
- Previous message: Optional.or name Re: RFR 8080418 Add Optional.or()
- Next message: JDK 9 RFR of JDK-8139407: Mark java/rmi/registry/readTest/readTest.sh as intermittently failing
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]