
Package ca.uhn.fhir.rest.api
Class SortSpec
- java.lang.Object
-
- ca.uhn.fhir.rest.api.SortSpec
-
- All Implemented Interfaces:
Serializable
public class SortSpec extends Object implements Serializable
Represents values for sorting resources returned by a server.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SortSpec()
ConstructorSortSpec(String theParamName)
ConstructorSortSpec(String theParamName, SortOrderEnum theOrder)
ConstructorSortSpec(String theParamName, SortOrderEnum theOrder, SortSpec theChain)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SortSpec
getChain()
Gets the chained sort specification, ornull
if none.SortOrderEnum
getOrder()
Returns the sort order specified by this parameter, ornull
if none is explicitly provided (which meansSortOrderEnum.ASC
according to the FHIR specification)String
getParamName()
Returns the actual name of the search param to sort bySortSpec
setChain(SortSpec theChain)
Sets the chained sort specification, ornull
if none.SortSpec
setOrder(SortOrderEnum theOrder)
Sets the sort order specified by this parameter, ornull
if none should be explicitly defined (which meansSortOrderEnum.ASC
according to the FHIR specification)SortSpec
setParamName(String theFieldName)
Sets the actual name of the search param to sort by
-
-
-
Constructor Detail
-
SortSpec
public SortSpec()
Constructor
-
SortSpec
public SortSpec(String theParamName)
Constructor- Parameters:
theParamName
- The search name to sort on. SeesetParamName(String)
for more information.
-
SortSpec
public SortSpec(String theParamName, SortOrderEnum theOrder)
Constructor- Parameters:
theParamName
- The search name to sort on. SeesetParamName(String)
for more information.theOrder
- The order, ornull
. SeesetOrder(SortOrderEnum)
for more information.
-
SortSpec
public SortSpec(String theParamName, SortOrderEnum theOrder, SortSpec theChain)
Constructor- Parameters:
theParamName
- The search name to sort on. SeesetParamName(String)
for more information.theOrder
- The order, ornull
. SeesetOrder(SortOrderEnum)
for more information.theChain
- The next sorting spec, to be applied only when this spec makes two entries equal. SeesetChain(SortSpec)
for more information.
-
-
Method Detail
-
getChain
public SortSpec getChain()
Gets the chained sort specification, ornull
if none. If multiple sort parameters are chained (indicating a sub-sort), the second level sort is chained via this property.
-
getParamName
public String getParamName()
Returns the actual name of the search param to sort by
-
getOrder
public SortOrderEnum getOrder()
Returns the sort order specified by this parameter, ornull
if none is explicitly provided (which meansSortOrderEnum.ASC
according to the FHIR specification)
-
setChain
public SortSpec setChain(SortSpec theChain)
Sets the chained sort specification, ornull
if none. If multiple sort parameters are chained (indicating a sub-sort), the second level sort is chained via this property.
-
setParamName
public SortSpec setParamName(String theFieldName)
Sets the actual name of the search param to sort by
-
setOrder
public SortSpec setOrder(SortOrderEnum theOrder)
Sets the sort order specified by this parameter, ornull
if none should be explicitly defined (which meansSortOrderEnum.ASC
according to the FHIR specification)
-
-