Commons Lang
  1. Commons Lang
  2. LANG-668

Change ObjectUtils min() & max() functions to use varargs rather than just two parameters

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.5
    • Fix Version/s: 3.0
    • Component/s: lang.*
    • Labels:
      None

      Description

      Currently ObjectUtils has min() and max() method with the following signatures:

      public static <T extends Comparable<? super T>> T min(T c1, T c2)
      public static <T extends Comparable<? super T>> T max(T c1, T c2)
      

      It would be useful to change these from taking just two parameters to any number using varags:

      public static <T extends Comparable<? super T>> T min(T... values)
      public static <T extends Comparable<? super T>> T max(T... values)
      

        Activity

        Show
        Niall Pemberton added a comment - Fixed: http://svn.apache.org/viewvc?view=revision&revision=1056134

          People

          • Assignee:
            Niall Pemberton
            Reporter:
            Niall Pemberton
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development