Optional.or name Re: RFR 8080418 Add Optional.or() (original) (raw)
Stefan Zobel spliterator at gmail.com
Mon Oct 12 08:17:12 UTC 2015
- Previous message: Optional.or name Re: RFR 8080418 Add Optional.or()
- Next message: Optional.or name Re: RFR 8080418 Add Optional.or()
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
“Optional.or” is the best name so far i have come up with. The “orElse” prefix is reversed for terminal methods and i don’t want to overload that. -- Alternative suggestions: - “Optional.otherwise” A bit of a mouthful, but reasonably accurate - “Optional.mapElse" The name is not entirely accurate since it accepts a Suppler not a T, a more accurate name would be the following alternative. - “Optional.flatMapElse" This name is likely to confuse. Paul.
- "Optional.orIfAbsent" perhaps?
Actually, I don't regard "Optional.or" as a poor name.
Stefan.
- Previous message: Optional.or name Re: RFR 8080418 Add Optional.or()
- Next message: Optional.or name Re: RFR 8080418 Add Optional.or()
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]