public class SortBuilders extends Object
SortBuilder
s.Constructor and Description |
---|
SortBuilders() |
Modifier and Type | Method and Description |
---|---|
static FieldSortBuilder |
fieldSort(String field)
Constructs a new field based sort.
|
static GeoDistanceSortBuilder |
geoDistanceSort(String fieldName)
A geo distance based sort.
|
static ScoreSortBuilder |
scoreSort()
Constructs a new score sort.
|
static ScriptSortBuilder |
scriptSort(Script script,
String type)
Constructs a new script based sort.
|
static ScriptSortBuilder |
scriptSort(String script,
String type)
Deprecated.
Use
scriptSort(Script, String) instead. |
public static ScoreSortBuilder scoreSort()
public static FieldSortBuilder fieldSort(String field)
field
- The field name.public static ScriptSortBuilder scriptSort(Script script, String type)
script
- The script to use.type
- The type, can either be "string" or "number".@Deprecated public static ScriptSortBuilder scriptSort(String script, String type)
scriptSort(Script, String)
instead.script
- The script to use.type
- The type, can either be "string" or "number".public static GeoDistanceSortBuilder geoDistanceSort(String fieldName)
fieldName
- The geo point like field name.Copyright © 2009–2016. All rights reserved.