Class FacetRequestOptions


  • public final class FacetRequestOptions
    extends Object
    The options for facet evaluation.
    • Constructor Detail

      • FacetRequestOptions

        public FacetRequestOptions()
    • Method Detail

      • sortBy

        public String sortBy()
        Get the sortBy property: The column name or query expression to sort on. Defaults to count if not present.
        Returns:
        the sortBy value.
      • withSortBy

        public FacetRequestOptions withSortBy​(String sortBy)
        Set the sortBy property: The column name or query expression to sort on. Defaults to count if not present.
        Parameters:
        sortBy - the sortBy value to set.
        Returns:
        the FacetRequestOptions object itself.
      • sortOrder

        public FacetSortOrder sortOrder()
        Get the sortOrder property: The sorting order by the selected column (count by default).
        Returns:
        the sortOrder value.
      • withSortOrder

        public FacetRequestOptions withSortOrder​(FacetSortOrder sortOrder)
        Set the sortOrder property: The sorting order by the selected column (count by default).
        Parameters:
        sortOrder - the sortOrder value to set.
        Returns:
        the FacetRequestOptions object itself.
      • filter

        public String filter()
        Get the filter property: Specifies the filter condition for the 'where' clause which will be run on main query's result, just before the actual faceting.
        Returns:
        the filter value.
      • withFilter

        public FacetRequestOptions withFilter​(String filter)
        Set the filter property: Specifies the filter condition for the 'where' clause which will be run on main query's result, just before the actual faceting.
        Parameters:
        filter - the filter value to set.
        Returns:
        the FacetRequestOptions object itself.
      • top

        public Integer top()
        Get the top property: The maximum number of facet rows that should be returned.
        Returns:
        the top value.
      • withTop

        public FacetRequestOptions withTop​(Integer top)
        Set the top property: The maximum number of facet rows that should be returned.
        Parameters:
        top - the top value to set.
        Returns:
        the FacetRequestOptions object itself.
      • validate

        public void validate()
        Validates the instance.
        Throws:
        IllegalArgumentException - thrown if the instance is not valid.