Comparable and Comparator
By jeanjiang
@jeanjiang (30)
China
April 24, 2011 1:20am CST
When I start to sort a collection, I can use Class - Comparable or Comparator.
My question is what is difference between Comparable and Comparator?
2 responses
@jeanjiang (30)
• China
24 Apr 11
Thanks jackycui, your article gives me a clear cognition about Comparable and Comparator
@owlwings (43910)
• Cambridge, England
24 Apr 11
You should find this helpful: http://www.javabeat.net/qna/633-difference-between-comparable-interface-and-c/
@owlwings (43910)
• Cambridge, England
24 Apr 11
and this: http://www.velocityreviews.com/forums/t141190-difference-between-comparator-and-comparable-interface.html