Enum NullHandling
- java.lang.Object
-
- java.lang.Enum<NullHandling>
-
- de.digitalcollections.model.list.sorting.NullHandling
-
- All Implemented Interfaces:
Serializable
,Comparable<NullHandling>
public enum NullHandling extends Enum<NullHandling>
Enumeration for null handling hints that can be used inOrder
expressions. See Spring Data Commons, but more flat design and independent of Spring libraries.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description NATIVE
Lets the data store decide what to do with nulls.NULLS_FIRST
A hint to the used data store to order entries with null values before non null entries.NULLS_LAST
A hint to the used data store to order entries with null values after non null entries.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static NullHandling
valueOf(String name)
Returns the enum constant of this type with the specified name.static NullHandling[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NATIVE
public static final NullHandling NATIVE
Lets the data store decide what to do with nulls.
-
NULLS_FIRST
public static final NullHandling NULLS_FIRST
A hint to the used data store to order entries with null values before non null entries.
-
NULLS_LAST
public static final NullHandling NULLS_LAST
A hint to the used data store to order entries with null values after non null entries.
-
-
Method Detail
-
values
public static NullHandling[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (NullHandling c : NullHandling.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static NullHandling valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
-