Back
Close

Java Guild Meeting 5/2018

Gi11i4m
73.1K views

Summary

Optionals is a concept that brings new advantages:

  • Use of type system to avoid runtime NullPointerException
  • Intention revealing APIs
  • Works nicely with Streams

But every new concept brings new responsibilities.

More optionals in Java 9+:

  • The or() method
  • The ifPresentOrElse() method
  • The stream() method
Create your playground on Tech.io
This playground was created on Tech.io, our hands-on, knowledge-sharing platform for developers.
Go to tech.io