public static enum NonNullableExpression.NullStrategy extends Enum<NonNullableExpression.NullStrategy>
null
-values.Enum Constant and Description |
---|
APPLY_DEFAULT_METHOD
|
THROW_EXCEPTION
|
USE_DEFAULT_VALUE
Whenever the
inner expression returns a
null value, a specific constant value will be returned by
this expression. |
Modifier and Type | Method and Description |
---|---|
static NonNullableExpression.NullStrategy |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static NonNullableExpression.NullStrategy[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final NonNullableExpression.NullStrategy USE_DEFAULT_VALUE
public static final NonNullableExpression.NullStrategy APPLY_DEFAULT_METHOD
inner
expression returns a
null
value, the
other
expression
will be invoked to determine the value instead. If this strategy is
used, then the class should also implement
OrElseGetExpression
.public static final NonNullableExpression.NullStrategy THROW_EXCEPTION
inner
expression returns a
null
value, a NullPointerException
is thrown. If this
strategy is used, then the class should also implement
OrElseThrowExpression
.public static NonNullableExpression.NullStrategy[] values()
for (NonNullableExpression.NullStrategy c : NonNullableExpression.NullStrategy.values()) System.out.println(c);
public static NonNullableExpression.NullStrategy valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullCopyright © 2019 Speedment, Inc.. All rights reserved.