Class DefaultSearchHelper
java.lang.Object
de.hybris.platform.cms2.common.service.impl.DefaultSearchHelper
- All Implemented Interfaces:
SearchHelper
Default implementation of
SearchHelper.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvertSort(String sort, SortDirection defaultSortDirection) Converts the String sort param into a list ofSortobjects.convertSortBlock(String sortBlock, SortDirection defaultSortDirection) Convert a sort block, i.e.
-
Constructor Details
-
DefaultSearchHelper
public DefaultSearchHelper()
-
-
Method Details
-
convertSort
Description copied from interface:SearchHelperConverts the String sort param into a list ofSortobjects. The input, if not empty, should be already validated with the following format: {param}:{direction} Multiple sort parameters are allowed if the blocks are separated by comma.- Specified by:
convertSortin interfaceSearchHelper- Parameters:
sort- - the sort parameter received from the requestdefaultSortDirection- the default sort direction if not supplied in any of the sortBlocks- Returns:
- a list of Sort objects
-
convertSortBlock
Description copied from interface:SearchHelperConvert a sort block, i.e. {param}:{direction} into aSortobject. When a sort direction is invalid or is not provided, the sort direction is defaulted to the defaultSortDirection param.- Specified by:
convertSortBlockin interfaceSearchHelper- Parameters:
sortBlock- a colon delimited String containing the sort field name and sorting directiondefaultSortDirection- the default sort direction if not supplied in the sortBlock- Returns:
- a
Sortobject
-