Value
Represents a field that was assigned a non-null value in the serialized entity. Equality and hashcode is implemented through its value.
Parameters
value
the value this optional wraps.
Properties
Link copied to clipboard
Link copied to clipboard
returns null
if this is null
, calls OptionalInt.asNullable otherwise.
Link copied to clipboard
Link copied to clipboard
returns null
if this is null
or OptionalInt.Missing, calls OptionalInt.Value.value otherwise.
Functions
Link copied to clipboard
Destructures this optional to its value.
Link copied to clipboard
returns the value of the optional or throws a IllegalStateException if the optional doesn't contain a value or is null
.
Link copied to clipboard
Link copied to clipboard
returns default if this is null
, calls OptionalInt.asNullable otherwise.