Optional is a container object which is used to contain not-null objects. An optional object is used to represent null with an absent value.
The Optional class has various utility methods to facilitate code to handle values as 'available' or 'not available' instead of checking null values.
The purpose of the Optional class is to provide a type-level solution for representing optional values instead of using null references.