Map.getOrDefault(Object,Supplier<V>) override

John Rose john.r.rose at
Thu Apr 18 19:01:47 PDT 2013

On Apr 18, 2013, at 6:56 PM, Jed Wesley-Smith <jed at> wrote:

> what's wrong with just using Optional

Map.get can produce nulls but Optional cannot consume them.

Otherwise, it's exactly what you need.  But I don't believe that is cause for revisiting the Optional-null question.  (I think there was a long thread about that a few weeks ago.  As an implementor I'm happy where the decision went.)

— John

More information about the lambda-dev mailing list