Lab 9: Interfaces

In this lab, we will be dealing with a hotel setting and attempting to keep track of our patrons. A patron has the following attributes:

For filing purposes, we are also going to declare an ordering for the patrons. Patrons will be dealt with alphabetically by name. If for some reason two patrons with the same name exist, the patron with the lower room number will be filed first. We will implement this ordering by having our Patron class implement the Comparable interface.

We will also store the patron's name in its own Name object that contains the patron's first and last names. This object will also implement the Comparable interface, since we need to be able to compare a pair of names. For names, you will compare last names first. If two people have the same last name, return the result of comparing the first names.