Class MCRSortBy

java.lang.Object
org.mycore.services.fieldquery.MCRSortBy

public class MCRSortBy extends Object
Represents a single sort criteria for sorting query results. Each MCRSortBy defines one field to sort by, and the order (ascending or descending).
Author:
Frank Lützenkirchen
  • Field Details

    • ASCENDING

      public static final boolean ASCENDING
      Sort this field in ascending order
      See Also:
    • DESCENDING

      public static final boolean DESCENDING
      Sort this field in descending order
      See Also:
  • Constructor Details

    • MCRSortBy

      public MCRSortBy(String fieldName, boolean order)
      Creates a new sort criteria
      Parameters:
      fieldName - the field to sort by
      order - the sort order (ascending or descending)
      See Also:
  • Method Details

    • getFieldName

      public String getFieldName()
    • getSortOrder

      public boolean getSortOrder()
      Returns the sort order for this field.
      Returns:
      true when order is ASCENDING or false whenorder is DESCENDING
      See Also: