edu.pdx.cs399J.core
Class PersonComparator
java.lang.Object
edu.pdx.cs399J.core.PersonComparator
- All Implemented Interfaces:
- Comparator<Person>
public class PersonComparator
- extends Object
- implements Comparator<Person>
This class is a Comparator that compares
Persons based on their shoe size.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PersonComparator
public PersonComparator()
compare
public int compare(Person o1,
Person o2)
- Specified by:
compare in interface Comparator<Person>
main
public static void main(String[] args)
- Creates a set of
Persons and prints out the
contents.
Copyright © 2000-2009 Portland State University. All Rights Reserved.