Annotation Type Sort


  • @Target({METHOD,FIELD})
    @Retention(RUNTIME)
    @Deprecated
    public @interface Sort
    Deprecated.
    Use SortComparator or SortNatural instead depending on need.
    Collection sort (in-memory sorting). Different than ordering, which is applied during the SQL select.
    See Also:
    OrderBy
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      java.lang.Class comparator
      Deprecated.
      Specifies the comparator to use.
      SortType type
      Deprecated.
      The type of sorting to use.
    • Element Detail

      • type

        SortType type
        Deprecated.
        The type of sorting to use. The default is to not use sorting.
        Default:
        org.hibernate.annotations.SortType.UNSORTED
      • comparator

        java.lang.Class comparator
        Deprecated.
        Specifies the comparator to use. Only valid when type() specifies SortType.COMPARATOR. TODO find a way to use Class<Comparator> -> see HHH-8164
        Default:
        void.class