You implement Comparable if you want to be able to sort a collection of your object by some "natural ordering"... using Collections.sort(...)
Collections use the equals(...) method to determine object equality and not compareTo(...) == 0. Some Collection implementations may implement this differently so always read the JavaDoc on the Collection implementation you are intending to use. Cheers, Renier --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CTJUG Forum" 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/CTJUG-Forum For the ctjug home page see http://www.ctjug.org.za -~----------~----~----~----~------~----~------~--~---
