Interfaces

Write two interfaces that each include 1 or more abstract methods. The interfaces cannot be ones that we used as examples in class or that are from our textbook (e.g. Movable, Locatable, or Measurable).

Design & implement 2 unrelated classes that realize both interfaces as well as the Comparable interface. For example, while the classes Helicopter and Lizard are not related to each other they would both implement Movable and Locatable.

Each of your two classes must include at least one interesting method that is not found in one of the interfaces.

Finally, write a client program named InterfacesTest that instantiates two objects from each of the two classes and that uses all available methods from those classes (included the compareTo method). You will be graded on the execution of the client program as well as how creative, interesting, and realistic your example is.

Your program must follow the class Coding Standards.

Preconditions:

    • None

You must hand in the following on separate pages stapled in this specified order:

    1. The source code for the two interfaces.
    2. The source code for the the two classes that implement the interfaces.
    3. The source code for the client program.
    4. The runtime output of the client program.