It seems to me there should be a method somewhere to determine the maximum of two Comparables.
There is of course the max function in java.lang.MATH that works on the numeric primitives, and BigDecimal has a max function. There is also a max function in Collections, which would require one to create a collection of your comparable objects to find the maximum. It seems to me that somewhere there should be a generic "max" function that takes two Comparables as arguments. Is it anywhere in the JDK? Is there a de-facto standard library that contains this functionality? I'll write my own, but it just seems like one of those things I would use often. Brian --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "The Java Posse" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/javaposse?hl=en -~----------~----~----~----~------~----~------~--~---
