Interface OptionalExpression<T>
- All Superinterfaces:
ComparableExpression<Optional<T>>, Expression<Optional<T>>
Representation of an Optional type in a query.
-
Method Summary
Modifier and TypeMethodDescriptionget()Accessor for the object within the Optional.Accessor for whether there is an object within the Optional.orElse(Expression<T> other) Accessor for the value expression (if present), otherwise return the other expression.Methods inherited from interface ComparableExpression
asc, desc, gt, gt, gteq, gteq, lt, lt, lteq, lteq, max, minMethods inherited from interface Expression
as, cast, count, countDistinct, eq, eq, instanceOf, ne, ne
-
Method Details
-
get
-
isPresent
BooleanExpression isPresent()Accessor for whether there is an object within the Optional.- Returns:
- Whether there is an expression
-
orElse
Accessor for the value expression (if present), otherwise return the other expression.- Parameters:
other- Other expression- Returns:
- Return the value if present, otherwise return other
-