On Thu, 21 Feb 2002 [EMAIL PROTECTED] wrote: > And so I had no reason not to add it :) See latest cvs commit message. The > only change I made in your code is that I return result1 rather than -1 or > 1. Maintaining the size might be important I guess.
IllegalArgumentException is a bit weird here in this context. While I agree it it probably the most appropriate exception when the arguments aren't comparable, the Comparator javadoc declares it throws a ClassCastException "if the arguments' types prevent it from being compared". I'm ok with the IllegalArgument, but you should still add javadoc to declare it since it isn't declared in the Comparator's API docs. As for returning result1 rather than 1 or -1, it doesn't matter to me. regards, michael -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
