Package edu.pdx.cs410J.examples
Class ClassComparator
java.lang.Object
edu.pdx.cs410J.examples.ClassComparator
- All Implemented Interfaces:
Comparator<Object>
This class is a
Comparator
that compares
Object
s based on the name of their classes.-
Constructor Summary
-
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
ClassComparator
public ClassComparator()
-
-
Method Details
-
compare
- Specified by:
compare
in interfaceComparator<Object>
-
main
Create a bunch of object and store them in a set using aClassComparator
.
-