Package org.kiwiproject.spring.data
Class KiwiSort
- java.lang.Object
-
- org.kiwiproject.spring.data.KiwiSort
-
public class KiwiSort extends Object
Describes a sort on a specific property that is applied to a result list.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classKiwiSort.DirectionSort direction.
-
Constructor Summary
Constructors Constructor Description KiwiSort()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description KiwiSortignoringCase()Specifies that the sort is not case sensitive, i.e.static KiwiSortof(String property, KiwiSort.Direction direction)Create a new instance.
-
-
-
Method Detail
-
of
public static KiwiSort of(String property, KiwiSort.Direction direction)
Create a new instance.If you want to specify that the sort is not case-sensitive, you can immediately call the
ignoringCase()in a fluent style.- Parameters:
property- the property the sort is applied todirection- the sort direction- Returns:
- a new instance
- Throws:
IllegalArgumentException- if property is blank or direction is null
-
ignoringCase
public KiwiSort ignoringCase()
Specifies that the sort is not case sensitive, i.e. it ignores case.- Returns:
- this instance, for method chaining
-
-